Core/Misc: Fix logic for owner check in Unit::RemoveGameObject

This commit is contained in:
Shocker
2012-03-26 02:50:08 +03:00
parent 9ec61089be
commit 48dc9313b9
+2 -1
View File
@@ -4624,7 +4624,8 @@ void Unit::AddGameObject(GameObject* gameObj)
void Unit::RemoveGameObject(GameObject* gameObj, bool del)
{
if (!gameObj || !gameObj->GetOwnerGUID() == GetGUID()) return;
if (!gameObj || gameObj->GetOwnerGUID() != GetGUID())
return;
gameObj->SetOwnerGUID(0);