aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormegamage <none@none>2009-08-25 00:56:23 -0500
committermegamage <none@none>2009-08-25 00:56:23 -0500
commitd14a4a237208a0d781dbef44c219340f3ba2b186 (patch)
treea92f94784ab99c5eb94c69c130d413e3cf9e2d77 /src
parent01530fb148333b4296de83815df91c69062c0df3 (diff)
*Fix the bug that sometimes vehicle is not usable after respawn.
--HG-- branch : trunk
Diffstat (limited to 'src')
-rw-r--r--src/game/Creature.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/game/Creature.cpp b/src/game/Creature.cpp
index a1cb9e5649f..8299d74f389 100644
--- a/src/game/Creature.cpp
+++ b/src/game/Creature.cpp
@@ -1794,9 +1794,7 @@ void Creature::setDeathState(DeathState s)
SetHealth(GetMaxHealth());
SetLootRecipient(NULL);
ResetPlayerDamageReq();
- Unit::setDeathState(ALIVE);
CreatureInfo const *cinfo = GetCreatureInfo();
- RemoveFlag (UNIT_FIELD_FLAGS, UNIT_FLAG_SKINNABLE);
AddUnitMovementFlag(MOVEMENTFLAG_WALK_MODE);
SetUInt32Value(UNIT_NPC_FLAGS, cinfo->npcflag);
clearUnitState(UNIT_STAT_ALL_STATE);
@@ -1805,6 +1803,7 @@ void Creature::setDeathState(DeathState s)
Motion_Initialize();
if(GetCreatureData() && GetPhaseMask() != GetCreatureData()->phaseMask)
SetPhaseMask(GetCreatureData()->phaseMask, false);
+ Unit::setDeathState(ALIVE);
}
}