mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-20 17:27:36 +01:00
*Cleanup of charm/farsight code. Hope this can fix some crash bugs.
--HG-- branch : trunk
This commit is contained in:
@@ -153,12 +153,7 @@ void WorldSession::HandlePetAction( WorldPacket & recv_data )
|
||||
p->setDeathState(CORPSE);
|
||||
}
|
||||
else // charmed or possessed
|
||||
{
|
||||
if (_player->isPossessing())
|
||||
_player->RemovePossess(true);
|
||||
else
|
||||
_player->Uncharm();
|
||||
}
|
||||
_player->Uncharm();
|
||||
break;
|
||||
default:
|
||||
sLog.outError("WORLD: unknown PET flag Action %i and spellid %i.\n", flag, spellid);
|
||||
@@ -495,12 +490,7 @@ void WorldSession::HandlePetAbandon( WorldPacket & recv_data )
|
||||
_player->RemovePet((Pet*)pet,PET_SAVE_AS_DELETED);
|
||||
}
|
||||
else if(pet->GetGUID() == _player->GetCharmGUID())
|
||||
{
|
||||
if (_player->isPossessing())
|
||||
_player->RemovePossess(true);
|
||||
else
|
||||
_player->Uncharm();
|
||||
}
|
||||
_player->Uncharm();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user