More warning removal (Some code modifications and cleanup when needed)

--HG--
branch : trunk
This commit is contained in:
Spp
2010-04-19 17:03:10 +02:00
parent f74e969a06
commit be01821050
46 changed files with 420 additions and 353 deletions

View File

@@ -1099,7 +1099,9 @@ WorldSafeLocsEntry const* BattleGroundAV::GetClosestGraveYard(Player* player)
for (uint8 i = BG_AV_NODES_FIRSTAID_STATION; i <= BG_AV_NODES_FROSTWOLF_HUT; ++i)
if (m_Nodes[i].Owner == player->GetTeam() && m_Nodes[i].State == POINT_CONTROLED)
if (entry = sWorldSafeLocsStore.LookupEntry(BG_AV_GraveyardIds[i]))
{
entry = sWorldSafeLocsStore.LookupEntry(BG_AV_GraveyardIds[i]);
if (entry)
{
dist = (entry->x - x)*(entry->x - x)+(entry->y - y)*(entry->y - y);
if (dist < minDist)
@@ -1108,6 +1110,7 @@ WorldSafeLocsEntry const* BattleGroundAV::GetClosestGraveYard(Player* player)
pGraveyard = entry;
}
}
}
return pGraveyard;
}