Go Back   EQEmulator Home > EQEmulator Forums > Archives > Archive::Development > Archive::Development

Archive::Development Archive area for Development's posts that were moved here after an inactivity period of 90 days.

Reply
 
Thread Tools Display Modes
  #1  
Old 12-11-2002, 11:14 PM
_dev_toaster
Fire Beetle
 
Join Date: Dec 2002
Posts: 4
Default Familiars patch :)

Ok, keep in mind a few things before looking at this coding mess. I have not done C++ coding in many years, and more or less forgot how I know it can be done much better. Maybe someone here has better experience with it and can update it before its merged.

I had to make a new MakePet() function to handle the pet name. I am not sure how you guys wanna handle that part. Remeber, beastlords are gonna need %s' warder

I also guessed at what level each familiar is them selfs. I am sure someone could add the correct values by coning an even one and noteing there level.

There are a few dozen peaces missing to this, like zoning. I didn't get started on my search to find out where to re-summon them durring zoning. /pet get lost doesn't appear to work correctly, (it says you already have a pet if you try to summon another one) and they don't disappear when the buff fades or is dropped. (they also need to be protected from dispells, since you can't dispell them) Currently, the pets will attack as well. I didn't get a chance to track down how to tell the client to disable those from the pet window.

Also, another VERY important note. I wasn't sure which is the correct op code for familairs to be summoned. So, I took a wild guess. If its wrong, change it.

#define SE_Familiar 0x70

-- diff of spells.cpp --

1114,1125d1113
< case SE_Familiar:
< if (this->GetPetID() != 0) {
< Message(13, "You\'ve already got a pet.");
< break;
< }
<
< this->MakePet(spells[spell_id].teleport_zone);
< this->CastToNPC()->SetPetType(0);
< this->SetOwnerID(caster->GetID());
< caster->SetPetID(this->GetID());
< break;
<
1732,1761d1719
< else if (strncmp(pettype, "Familiar1",9) == 0) {
< char f_name[50];
< strcpy(f_name,this->GetName());
< strcat(f_name,"'s Familiar");
< MakePet(27,1,46,1,0,3,0,f_name);
< }
< else if (strncmp(pettype, "Familiar2",9) == 0) {
< char f_name[50];
< strcpy(f_name,this->GetName());
< strcat(f_name,"'s Familiar");
< MakePet(47,1,46,1,0,3,0,f_name);
< }
< else if (strncmp(pettype, "Familiar3",9) == 0) {
< char f_name[50];
< strcpy(f_name,this->GetName());
< strcat(f_name,"'s Familiar");
< MakePet(50,1,89,4,0,3,0,f_name);
< }
< else if (strncmp(pettype, "Familiar4",9) == 0) {
< char f_name[50];
< strcpy(f_name,this->GetName());
< strcat(f_name,"'s Familiar");
< MakePet(58,1,89,4,0,3,0,f_name);
< }
< else if (strncmp(pettype, "Familiar5",9) == 0) {
< char f_name[50];
< strcpy(f_name,this->GetName());
< strcat(f_name,"'s Familiar");
< MakePet(60,1,89,1,0,3,0,f_name);
< }
1775,1840c1733,1740
< if (! name)
< {
< if (this->IsClient())
< strcpy(npc_type->name, GetRandPetName());
< else {
< strcpy(npc_type->name, this->GetName());
< npc_type->name[29] = 0;
< npc_type->name[28] = 0;
< npc_type->name[19] = 0;
< strcat(npc_type->name, "'s_pet");
< }
< }
< else
< {
< strcpy(npc_type->name,name);
< }
< npc_type->level = in_level;
< npc_type->race = in_race;
< npc_type->class_ = in_class;
< npc_type->texture = in_texture;
< npc_type->helmtexture = in_texture;
< npc_type->size = in_size;
< npc_type->max_hp = CalcPetHp(npc_type->level, npc_type->class_);
< npc_type->cur_hp = npc_type->max_hp;
< npc_type->fixedZ = 1;
<
< switch(type)
< {
< case 15: // Mage Epic Pet
< {
< npc_type->max_hp = 3000;
< npc_type->cur_hp = 3000;
< npc_type->min_dmg = 0;
< npc_type->max_dmg = 25;
< sprintf(npc_type->npc_spells,"847 848 849");
< break;
< }
< case 2: // Enchanter Pet
< {
< npc_type->gender = 0;
< npc_type->equipment[7] = 34;
< npc_type->equipment[8] = 202;
< break;
< }
< case 11: // Druid Pet... Baron-Sprite: Info from www.eqdruids.com said about 100 hp.
< {
< npc_type->max_hp = 100;
< npc_type->cur_hp = 100;
< npc_type->min_dmg = 17;
< npc_type->max_dmg = 25;
< break;
< }
< default:
< break;
< }
< NPC* npc = new NPC(npc_type, 0, this->GetX(), this->GetY(), this->GetZ(), this->GetHeading());
< delete npc_type;
< npc->SetPetType(in_pettype);
< npc->SetOwnerID(this->GetID());
< entity_list.AddNPC(npc);
< this->SetPetID(npc->GetID());
< }
<
< void Mob::MakePet(int8 in_level, int8 in_class, int16 in_race, int8 in_texture, int8 in_pettype, float in_size, int8 type, char* name) {
< if (this->GetPetID() != 0) {
< return;
---
> if (this->IsClient())
> strcpy(npc_type->name, GetRandPetName());
> else {
> strcpy(npc_type->name, this->GetName());
> npc_type->name[29] = 0;
> npc_type->name[28] = 0;
> npc_type->name[19] = 0;
> strcat(npc_type->name, "'s_pet");
1842,1847d1741
<
< NPCType* npc_type = new NPCType;
< memset(npc_type, 0, sizeof(NPCType));
< npc_type->gender = 2;
<
< strcpy(npc_type->name,name);
1894d1787
<

-- end diff --

I also thought of an intresting non-standard eqlive idea. GMs should be able to summon a different colored familiar. I figured a red drake would be kinda cool. I didn't add that in there, becuase I wasn't sure how people would react to it. Either way, I think its a cool idea.

Enjoy
Reply With Quote
  #2  
Old 12-12-2002, 04:35 AM
kathgar
Discordant
 
Join Date: May 2002
Posts: 434
Default

Doesn't /pet get lost just make them disappear and stop flapping, but you still get the bennefits?
__________________
++[>++++++<-]>[<++++++>-]<.>++++[>+++++<-]>[<
+++++>-]<+.+++++++..+++.>>+++++[<++++++>-]<+
+.<<+++++++++++++++.>.+++.------.--------.>+.
Reply With Quote
  #3  
Old 12-12-2002, 06:39 AM
neotokyo
Hill Giant
 
Join Date: Oct 2002
Posts: 118
Default

Quote:
Originally Posted by kathgar
Doesn't /pet get lost just make them disappear and stop flapping, but you still get the bennefits?
yes /pet get lost just kills the familiar with the spell buff icon still being visible, and the familar comes back into existance after zoning if you still have that buff IIRC

*edit: IIRC you can even have the wizard pet (sword of xuxl???) and the familiar at the same time*

*edit2: gonna put that familiar pets in, i wonder how the improved familiar looks like, and how we gonna test it since the spell will be POP item, and we dont have any yet, and i wonder if i can stop writing so much bullshit ...*
Reply With Quote
  #4  
Old 12-12-2002, 07:31 AM
_dev_toaster
Fire Beetle
 
Join Date: Dec 2002
Posts: 4
Default

Yes, the buff stays when you do /pet get lost. I ment, when the buff fades, or you remove the buff ... it doesn't issue a /pet get lost.

When you do a /pet get lost, remove the pet then try to cast another familiar, it has problems. Says you already have a pet, I belive its a bug in the pet code.

I don't know what the PoP familiar looks like. But, I just relized a mistake I made in my code. Familiar4 is the SoL aaxp familiar, which is green. I don't know about the PoP familiar, that will need to be changed.
Reply With Quote
  #5  
Old 12-12-2002, 07:32 AM
Baron Sprite's Avatar
Baron Sprite
Dragon
 
Join Date: Jan 2002
Posts: 708
Default

Check your PM please toaster.
__________________
Waking up in the morgue is pretty harsh, but it beats being dead.
Begun, this irc stat war has.
Reply With Quote
  #6  
Old 12-12-2002, 08:18 AM
Nivisec
Fire Beetle
 
Join Date: Dec 2002
Posts: 9
Default

You guys might already know of this site, but jsut in case here it is.

http://www.graffe.com/

You can find information on all the wizard stuff in the forums here. Lots of capped out powergaming wizards hang there and can answer any wizard related questions too like what pets look like and damage caps of spells, etc

My last char I took up towards 60 was a wizzy so I learned all I could about them, and this site was helpful.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 09:43 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3