Updates to fix taunt button on PET UI to match live behavior.

This commit is contained in:
Noudess
2020-09-02 12:50:11 -04:00
parent 29f7bc7a9c
commit 56afa0404b
9 changed files with 29 additions and 12 deletions
+5 -2
View File
@@ -1245,7 +1245,8 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial, int level_ove
MakePet(spell_id, spell.teleport_zone);
// TODO: we need to sync the states for these clients ...
// Will fix buttons for now
if (IsClient()) {
Mob *pet=GetPet();
if (IsClient() && pet) {
auto c = CastToClient();
if (c->ClientVersionBit() & EQ::versions::maskUFAndLater) {
c->SetPetCommandState(PET_BUTTON_SIT, 0);
@@ -1253,7 +1254,9 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial, int level_ove
c->SetPetCommandState(PET_BUTTON_REGROUP, 0);
c->SetPetCommandState(PET_BUTTON_FOLLOW, 1);
c->SetPetCommandState(PET_BUTTON_GUARD, 0);
c->SetPetCommandState(PET_BUTTON_TAUNT, 1);
// Creating pet from spell - taunt always false
// If suspended pet - that will be restore there
// If logging in, client will send toggle
c->SetPetCommandState(PET_BUTTON_HOLD, 0);
c->SetPetCommandState(PET_BUTTON_GHOLD, 0);
c->SetPetCommandState(PET_BUTTON_FOCUS, 0);