aboutsummaryrefslogtreecommitdiff
path: root/src/game/Unit.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game/Unit.cpp')
-rw-r--r--src/game/Unit.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp
index 90eab95401b..6bdb04cd90f 100644
--- a/src/game/Unit.cpp
+++ b/src/game/Unit.cpp
@@ -11971,8 +11971,7 @@ void Unit::SetHealth(uint32 val)
{
if(getDeathState() == JUST_DIED)
val = 0;
- // causes instant permadeath if you exit game while in combat?! :-|
- else if((GetTypeId() == TYPEID_PLAYER) && (getDeathState() & (DEAD | DEAD_FALLING)) != 0)
+ else if(GetTypeId() == TYPEID_PLAYER && (getDeathState() == DEAD || getDeathState() == DEAD_FALLING))
val = 1;
else
{