Replace World::getConfig with World::getFloatConfig, World::getIntConfig, and World::getBoolConfig.

Also fix a warning from a previous commit.

--HG--
branch : trunk
This commit is contained in:
silinoron
2010-08-23 19:56:47 -07:00
parent b30800e9bc
commit 8649bee17f
65 changed files with 885 additions and 889 deletions
+1 -1
View File
@@ -126,7 +126,7 @@ void GuardAI::UpdateAI(const uint32 /*diff*/)
bool GuardAI::IsVisible(Unit *pl) const
{
return me->IsWithinDist(pl,(float)sWorld.getConfig(CONFIG_SIGHT_GUARDER))
return me->IsWithinDist(pl,sWorld.getFloatConfig(CONFIG_SIGHT_GUARDER))
&& pl->isVisibleForOrDetect(me,true);
}
+1 -1
View File
@@ -126,7 +126,7 @@ void CreatureAI::MoveInLineOfSight(Unit *who)
if (me->canStartAttack(who, false))
AttackStart(who);
//else if (who->getVictim() && me->IsFriendlyTo(who)
// && me->IsWithinDistInMap(who, sWorld.getConfig(CONFIG_CREATURE_FAMILY_ASSISTANCE_RADIUS))
// && me->IsWithinDistInMap(who, sWorld.getIntConfig(CONFIG_CREATURE_FAMILY_ASSISTANCE_RADIUS))
// && me->canStartAttack(who->getVictim(), true)) // TODO: if we use true, it will not attack it when it arrives
// me->GetMotionMaster()->MoveChase(who->getVictim());
}