|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Development::Bug Reports Post detailed bug reports and what you would like to see next in the emu here. |
|
|
|
09-27-2008, 08:49 PM
|
Fire Beetle
|
|
Join Date: Nov 2007
Posts: 2
|
|
Fear on PC's Pet breakable with /pet back?
I was playing on the Zeb server the other night, fighting against some Cleric-class NPCs, and my pet got feared. Not realizing right away why my pet was running around like a chicken with no head, I used the /pet back command and it returned to my side, whereupon I commanded it to attack again, which it did. After this I noticed that it had a Fear spell on it, which should have prevented it from obeying my commands. Continuing my battles, I was able to reproduce it again, when the pet is feared, it still will obey commands, which effectively means that if your pet is feared, you can just issue it a /pet back, and it breaks the Fear effect, but not the spell, as it does not cause the icon in the pet's buff window to go away.
If this bug has already been noted I apologize, I did a quick once over and didn't see it posted already but its possible I missed it. This bug would be easy to exploit, and honestly, it would be easy to exploit it unintentionally, as that is how I found it, not realizing my pet was feared at first.
While I'm typing here I would like to thank each and every person who has worked on the EQEmu/PEQ projects for all your hard work, I have been playing EQ since Classic (pre-Kunark), and it's awesome to have this game availible to play, for free, unspoiled by the purely money-driven interests of SOE. Thanks, y'all!!!!
That's all I have to say, thanks again for bringing us our favorite MMORPG, for free!!!
Gundalph out.
|
|
|
|
|
|
|
09-28-2008, 02:14 AM
|
Developer
|
|
Join Date: Mar 2007
Location: Ohio
Posts: 648
|
|
Pet commands are handled in zone/client_packet.cpp:
Code:
void Client::Handle_OP_PetCommands(const EQApplicationPacket *app)
{
char val1[20]={0};
PetCommand_Struct* pet = (PetCommand_Struct*) app->pBuffer;
Mob* mypet = this->GetPet();
if(!mypet) return;
if(mypet->GetPetType() == petAnimation && (pet->command != PET_HEALTHREPORT && pet->command != PET_GETLOST) && !GetAA(aaAnimationEmpathy))
return;
// just let the command "/pet get lost" work for familiars
if(mypet->GetPetType() == petFamiliar && pet->command != PET_GETLOST)
return;
switch(pet->command) {
case PET_ATTACK: {
if (!target)
break;
if (target->IsMezzed()) {
Message_StringID(10, CANNOT_WAKE, mypet->GetCleanName(), target->GetCleanName());
break;
}
if((mypet->GetPetType() == petAnimation && GetAA(aaAnimationEmpathy) >= 2) || mypet->GetPetType() != petAnimation) {
if (mypet->GetHateTop()==0 && target != this && DistNoRootNoZ(*target) <= (RuleR(Pets, AttackCommandRange)*RuleR(Pets, AttackCommandRange))) {
mypet->SetHeld(false); //break the hold and guard if we explicitly tell the pet to attack.
mypet->SetPetOrder(SPO_Follow);
zone->AddAggroMob();
mypet->AddToHateList(target, 1);
Message_StringID(10, PET_ATTACKING, mypet->GetCleanName(), target->GetCleanName());
}
}
break;
}
case PET_BACKOFF: {
if((mypet->GetPetType() == petAnimation && GetAA(aaAnimationEmpathy) >= 3) || mypet->GetPetType() != petAnimation) {
mypet->Say_StringID(PET_CALMING);
mypet->WhipeHateList();
}
break;
}
case PET_HEALTHREPORT: {
Message_StringID(10, PET_REPORT_HP, ConvertArrayF(mypet->GetHPRatio(), val1));
mypet->ShowBuffList(this);
//Message(10,"%s tells you, 'I have %d percent of my hit points left.'",mypet->GetName(),(int8)mypet->GetHPRatio());
break;
}
case PET_GETLOST: {
if (mypet->Charmed())
break;
if (mypet->GetPetType() == petCharmed || !mypet->IsNPC()) {
// eqlive ignores this command
// we could just remove the charm
// and continue
mypet->BuffFadeByEffect(SE_Charm);
break;
} else {
SetPet(NULL);
}
mypet->Say_StringID(PET_GETLOST_STRING);
mypet->CastToNPC()->Depop();
// WildcardX: Oddly, the client (Titanium) will still allow "/pet get lost" command despite me adding the code below. If someone can figure that out, you can uncomment this code and use it.
/*
if((mypet->GetPetType() == petAnimation && GetAA(aaAnimationEmpathy) >= 2) || mypet->GetPetType() != petAnimation) {
mypet->Say_StringID(PET_GETLOST_STRING);
mypet->CastToNPC()->Depop();
}
*/
break;
}
case PET_LEADER: {
mypet->Say_StringID(PET_LEADERIS);
break;
}
case PET_GUARDHERE: {
if((mypet->GetPetType() == petAnimation && GetAA(aaAnimationEmpathy) >= 1) || mypet->GetPetType() != petAnimation) {
if(mypet->IsNPC()) {
mypet->SetHeld(false);
mypet->Say_StringID(PET_GUARDINGLIFE);
mypet->SetPetOrder(SPO_Guard);
mypet->CastToNPC()->SaveGuardSpot();
}
}
break;
}
case PET_FOLLOWME: {
if((mypet->GetPetType() == petAnimation && GetAA(aaAnimationEmpathy) >= 1) || mypet->GetPetType() != petAnimation) {
mypet->SetHeld(false);
mypet->Say_StringID(PET_FOLLOWING);
mypet->SetPetOrder(SPO_Follow);
mypet->SendAppearancePacket(AT_Anim, ANIM_STAND);
}
break;
}
case PET_TAUNT: {
if((mypet->GetPetType() == petAnimation && GetAA(aaAnimationEmpathy) >= 3) || mypet->GetPetType() != petAnimation) {
Message(0,"%s says, 'Now taunting foes, Master!",mypet->GetCleanName());
mypet->CastToNPC()->SetTaunting(true);
}
break;
}
case PET_NOTAUNT: {
if((mypet->GetPetType() == petAnimation && GetAA(aaAnimationEmpathy) >= 3) || mypet->GetPetType() != petAnimation) {
Message(0,"%s says, 'No longer taunting foes, Master!",mypet->GetCleanName());
mypet->CastToNPC()->SetTaunting(false);
}
break;
}
case PET_GUARDME: {
if((mypet->GetPetType() == petAnimation && GetAA(aaAnimationEmpathy) >= 1) || mypet->GetPetType() != petAnimation) {
mypet->SetHeld(false);
mypet->Say_StringID(PET_GUARDME_STRING);
mypet->SetPetOrder(SPO_Follow);
mypet->SendAppearancePacket(AT_Anim, ANIM_STAND);
}
break;
}
case PET_SITDOWN: {
if((mypet->GetPetType() == petAnimation && GetAA(aaAnimationEmpathy) >= 3) || mypet->GetPetType() != petAnimation) {
mypet->Say_StringID(PET_SIT_STRING);
mypet->SetPetOrder(SPO_Sit);
mypet->SetRunAnimSpeed(0);
if(!mypet->UseBardSpellLogic()) // solar: maybe we can have a bard pet
mypet->InterruptSpell(); //Baron-Sprite: No cast 4 u. // neotokyo: i guess the pet should start casting
mypet->SendAppearancePacket(AT_Anim, ANIM_SIT);
}
break;
}
case PET_STANDUP: {
if((mypet->GetPetType() == petAnimation && GetAA(aaAnimationEmpathy) >= 3) || mypet->GetPetType() != petAnimation) {
mypet->Say_StringID(PET_SIT_STRING);
mypet->SetPetOrder(SPO_Follow);
mypet->SendAppearancePacket(AT_Anim, ANIM_STAND);
}
break;
}
case PET_SLUMBER: {
if(mypet->GetPetType() != petAnimation) {
mypet->Say_StringID(PET_SIT_STRING);
mypet->SetPetOrder(SPO_Sit);
mypet->SetRunAnimSpeed(0);
if(!mypet->UseBardSpellLogic()) // solar: maybe we can have a bard pet
mypet->InterruptSpell(); //Baron-Sprite: No cast 4 u. // neotokyo: i guess the pet should start casting
mypet->SendAppearancePacket(AT_Anim, ANIM_DEATH);
}
break;
}
case PET_HOLD: {
if(GetAA(aaPetDiscipline) && mypet->IsNPC()){
mypet->Say("I will hold until given an order, master.");
mypet->WhipeHateList();
mypet->SetHeld(true);
mypet->SetPetOrder(SPO_Guard);
mypet->CastToNPC()->SaveGuardSpot();
}
}
default:
printf("Client attempted to use a unknown pet command:\n");
break;
}
}
I believe you should be able to add a check like this for each command that they shouldn't be able to respond to:
Code:
if (mypet->IsFeared()) break;
So, to fix /pet back specifically, after
Code:
case PET_BACKOFF: {
add
Code:
if (mypet->IsFeared()) break;
If I'm not mistaken, we'll need to do the same thing for /pet attack, /pet get lost, /pet guard here, /pet follow, /pet guard me, /pet sit, /pet stand, /pet slumber, and /pet hold. I think that just leaves us with /pet health, /pet leader, and /pet taunt.
|
|
|
|
09-28-2008, 01:23 PM
|
Fire Beetle
|
|
Join Date: Nov 2007
Posts: 2
|
|
That looks like it would work to me but I know little of such things. Neither a server admin nor a programmer am I. Just a player who thinks he found a bug that needs fixed, doing his part to help make the Emu better.
Has anyone else confirmed this bug? I'm fair certain of my observations but it would be good to have someone else verify my findings, if only to know that I wasn't just having a lag or client issue, or that it wasn't something specific to that particular server.
- Gundalph
|
09-29-2008, 02:47 AM
|
|
Developer
|
|
Join Date: Mar 2003
Posts: 1,497
|
|
Actually I was just bitching about my 65 pet being feared yesterday in SSRA. I tried back and it didn't bring him back to me. He stayed feared and kept darting through that area of the zone. So maybe it was a coincidence or a fluke?
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -4. The time now is 02:20 AM.
|
|
|
|
|
|
|
|
|
|
|
|
|