[7745] Fixed gcc warnings. Author: AlexDereka

--HG--
branch : trunk
This commit is contained in:
megamage
2009-05-03 22:21:46 -05:00
parent 5f167c56ef
commit 1cfc04f1f5
18 changed files with 62 additions and 37 deletions
+3 -2
View File
@@ -320,8 +320,9 @@ HostilReference* ThreatContainer::selectNextVictim(Creature* pAttacker, HostilRe
break;
}
if( currentRef->getThreat() > 1.3f * pCurrentVictim->getThreat() ||
currentRef->getThreat() > 1.1f * pCurrentVictim->getThreat() && pAttacker->IsWithinMeleeRange(target) )
if ((currentRef->getThreat() > 1.3f * pCurrentVictim->getThreat() ||
currentRef->getThreat() > 1.1f * pCurrentVictim->getThreat()) &&
pAttacker->IsWithinMeleeRange(target))
{ //implement 110% threat rule for targets in melee range
found = true; //and 130% rule for targets in ranged distances
break; //for selecting alive targets