[11397] Prevent happens one from cases "alive ghost" state.

Sometime levelup possible for dead player, prevent reset health in this case.
This commit is contained in:
VladimirMangos 2011-04-26 04:46:21 +04:00
parent 66ba7d2c49
commit 66598c8815
2 changed files with 3 additions and 2 deletions

View file

@ -2618,7 +2618,8 @@ void Player::GiveLevel(uint32 level)
UpdateAllStats();
// set current level health and mana/energy to maximum after applying all mods.
SetHealth(GetMaxHealth());
if (isAlive())
SetHealth(GetMaxHealth());
SetPower(POWER_MANA, GetMaxPower(POWER_MANA));
SetPower(POWER_ENERGY, GetMaxPower(POWER_ENERGY));
if(GetPower(POWER_RAGE) > GetMaxPower(POWER_RAGE))

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "11396"
#define REVISION_NR "11397"
#endif // __REVISION_NR_H__