fix(Core/Spells): Fix spellclick (#8232)

This commit is contained in:
IntelligentQuantum 2021-11-21 15:51:21 +03:30 committed by GitHub
parent b714e37c6c
commit faa4035de7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -642,6 +642,11 @@ void WorldSession::HandleSpellClick(WorldPacket& recvData)
if (!unit)
return;
if (_player->IsHostileTo(unit))
{
return;
}
// TODO: Unit::SetCharmedBy: 28782 is not in world but 0 is trying to charm it! -> crash
if (!unit->IsInWorld())
return;