Pet level-synchronization with owner should be done before initializing stats, closes issue 3732, thanks moriquendu

--HG--
branch : trunk
This commit is contained in:
Shocker
2010-08-31 20:40:43 +03:00
parent 46679c1bf7
commit e32ece52ea

View File

@@ -236,6 +236,7 @@ bool Pet::LoadPetFromDB(Player* owner, uint32 petentry, uint32 petnumber, bool c
SetReactState(ReactStates(fields[6].GetUInt8()));
SetCanModifyStats(true);
SynchronizeLevelWithOwner();
InitStatsForLevel(petlevel);
if (getPetType() == SUMMON_PET && !current) //all (?) summon pets come with full health when called, but not when they are current
@@ -341,7 +342,6 @@ bool Pet::LoadPetFromDB(Player* owner, uint32 petentry, uint32 petnumber, bool c
m_loading = false;
SynchronizeLevelWithOwner();
return true;
}