Misc: replace Unit::GetPlayer with ObjectAccessor::GetPlayer and some cosmetic changes

This commit is contained in:
joschiwald
2013-08-18 01:41:10 +02:00
parent c32dbd1432
commit 2b19ba1879
37 changed files with 263 additions and 300 deletions
+4 -2
View File
@@ -343,7 +343,7 @@ void SmartAI::UpdateAI(uint32 diff)
{
if (me->FindNearestCreature(mFollowArrivedEntry, INTERACTION_DISTANCE, true))
{
if (Player* player = me->GetPlayer(*me, mFollowGuid))
if (Player* player = ObjectAccessor::GetPlayer(*me, mFollowGuid))
{
if (!mFollowCreditType)
player->RewardPlayerAndGroupAtEvent(mFollowCredit, me);
@@ -365,7 +365,9 @@ void SmartAI::UpdateAI(uint32 diff)
return;
}
mFollowArrivedTimer = 1000;
} else mFollowArrivedTimer -= diff;
}
else
mFollowArrivedTimer -= diff;
}
if (!UpdateVictim())