aboutsummaryrefslogtreecommitdiff
path: root/src/game/Creature.cpp
diff options
context:
space:
mode:
authormegamage <none@none>2009-02-25 17:53:05 -0600
committermegamage <none@none>2009-02-25 17:53:05 -0600
commitccde296fd3822898e8959c009211fe880a0429f7 (patch)
tree431667bbae9ca263b572a8d9fd07fb36edbf3472 /src/game/Creature.cpp
parent8770a90bc6389d123a2716079bde40f43fc26357 (diff)
*Fix some crash bugs.
--HG-- branch : trunk
Diffstat (limited to 'src/game/Creature.cpp')
-rw-r--r--src/game/Creature.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/game/Creature.cpp b/src/game/Creature.cpp
index ece6ea3e527..e2a9fab0998 100644
--- a/src/game/Creature.cpp
+++ b/src/game/Creature.cpp
@@ -1662,7 +1662,8 @@ void Creature::setDeathState(DeathState s)
{
SetUInt64Value (UNIT_FIELD_TARGET,0); // remove target selection in any cases (can be set at aura remove in Unit::setDeathState)
SetUInt32Value(UNIT_NPC_FLAGS, 0);
- setActive(false);
+ if(!isPet())
+ setActive(false);
if(!isPet() && GetCreatureInfo()->SkinLootId)
if ( LootTemplates_Skinning.HaveLootFor(GetCreatureInfo()->SkinLootId) )
@@ -1675,8 +1676,8 @@ void Creature::setDeathState(DeathState s)
}
if(s == JUST_ALIVED)
{
- if(isPet())
- setActive(true);
+ //if(isPet())
+ // setActive(true);
SetHealth(GetMaxHealth());
SetLootRecipient(NULL);
Unit::setDeathState(ALIVE);