Core: Fix more warnings, add new function sLog.outStaticDebug() that replaces DEBUG_LOG

--HG--
branch : trunk
This commit is contained in:
click
2010-08-22 01:57:04 +02:00
parent a40cb46e61
commit 670964803f
29 changed files with 171 additions and 171 deletions
+6 -6
View File
@@ -61,7 +61,7 @@ void GuardAI::EnterEvadeMode()
{
if (!me->isAlive())
{
DEBUG_LOG("Creature stopped attacking because he is dead [guid=%u]", me->GetGUIDLow());
sLog.outStaticDebug("Creature stopped attacking because he is dead [guid=%u]", me->GetGUIDLow());
me->GetMotionMaster()->MoveIdle();
i_state = STATE_NORMAL;
@@ -76,23 +76,23 @@ void GuardAI::EnterEvadeMode()
if (!victim)
{
DEBUG_LOG("Creature stopped attacking because victim does not exist [guid=%u]", me->GetGUIDLow());
sLog.outStaticDebug("Creature stopped attacking because victim does not exist [guid=%u]", me->GetGUIDLow());
}
else if (!victim ->isAlive())
{
DEBUG_LOG("Creature stopped attacking because victim is dead [guid=%u]", me->GetGUIDLow());
sLog.outStaticDebug("Creature stopped attacking because victim is dead [guid=%u]", me->GetGUIDLow());
}
else if (victim ->HasStealthAura())
{
DEBUG_LOG("Creature stopped attacking because victim is using stealth [guid=%u]", me->GetGUIDLow());
sLog.outStaticDebug("Creature stopped attacking because victim is using stealth [guid=%u]", me->GetGUIDLow());
}
else if (victim ->isInFlight())
{
DEBUG_LOG("Creature stopped attacking because victim is flying away [guid=%u]", me->GetGUIDLow());
sLog.outStaticDebug("Creature stopped attacking because victim is flying away [guid=%u]", me->GetGUIDLow());
}
else
{
DEBUG_LOG("Creature stopped attacking because victim outran him [guid=%u]", me->GetGUIDLow());
sLog.outStaticDebug("Creature stopped attacking because victim outran him [guid=%u]", me->GetGUIDLow());
}
me->RemoveAllAuras();
+2 -2
View File
@@ -64,7 +64,7 @@ void PetAI::_stopAttack()
{
if (!me->isAlive())
{
DEBUG_LOG("Creature stoped attacking cuz his dead [guid=%u]", me->GetGUIDLow());
sLog.outStaticDebug("Creature stoped attacking cuz his dead [guid=%u]", me->GetGUIDLow());
me->GetMotionMaster()->Clear();
me->GetMotionMaster()->MoveIdle();
me->CombatStop();
@@ -96,7 +96,7 @@ void PetAI::UpdateAI(const uint32 diff)
{
if (_needToStop())
{
DEBUG_LOG("Pet AI stoped attacking [guid=%u]", me->GetGUIDLow());
sLog.outStaticDebug("Pet AI stoped attacking [guid=%u]", me->GetGUIDLow());
_stopAttack();
return;
}
+1 -1
View File
@@ -97,7 +97,7 @@ namespace FactorySelector
// select NullCreatureAI if not another cases
ainame = (ai_factory == NULL) ? "NullCreatureAI" : ai_factory->key();
DEBUG_LOG("Creature %u used AI is %s.", creature->GetGUIDLow(), ainame.c_str());
sLog.outStaticDebug("Creature %u used AI is %s.", creature->GetGUIDLow(), ainame.c_str());
return (ai_factory == NULL ? new NullCreatureAI(creature) : ai_factory->Create(creature));
}