*Fix a bug about pet talents.

--HG--
branch : trunk
This commit is contained in:
megamage
2009-04-03 17:29:27 -06:00
parent ef3295d279
commit 837e15405d
+2 -5
View File
@@ -150,9 +150,7 @@ bool Pet::LoadPetFromDB( Player* owner, uint32 petentry, uint32 petnumber, bool
float px, py, pz; float px, py, pz;
owner->GetClosePoint(px, py, pz, GetObjectSize(), PET_FOLLOW_DIST, PET_FOLLOW_ANGLE); owner->GetClosePoint(px, py, pz, GetObjectSize(), PET_FOLLOW_DIST, PET_FOLLOW_ANGLE);
Relocate(px, py, pz, owner->GetOrientation()); Relocate(px, py, pz, owner->GetOrientation());
if(!IsPositionValid()) if(!IsPositionValid())
{ {
sLog.outError("Pet (guidlow %d, entry %d) not loaded. Suggested coordinates isn't valid (X: %f Y: %f)", sLog.outError("Pet (guidlow %d, entry %d) not loaded. Suggested coordinates isn't valid (X: %f Y: %f)",
@@ -242,6 +240,8 @@ bool Pet::LoadPetFromDB( Player* owner, uint32 petentry, uint32 petnumber, bool
map->Add((Creature*)this); map->Add((Creature*)this);
owner->SetGuardian(this, true); owner->SetGuardian(this, true);
m_resetTalentsCost = fields[17].GetUInt32();
m_resetTalentsTime = fields[18].GetUInt64();
learnLevelupSpells(); learnLevelupSpells();
LearnPetPassives(); LearnPetPassives();
_LoadSpells(); _LoadSpells();
@@ -293,9 +293,6 @@ bool Pet::LoadPetFromDB( Player* owner, uint32 petentry, uint32 petnumber, bool
} }
} }
m_resetTalentsCost = fields[17].GetUInt32();
m_resetTalentsTime = fields[18].GetUInt64();
delete result; delete result;
//load spells/cooldowns/auras //load spells/cooldowns/auras