Core/: Fix warnings

--HG--
branch : trunk
This commit is contained in:
Spp
2010-09-21 10:11:25 +02:00
parent 63aa6e44fb
commit 7a3fd2e9bf
6 changed files with 16 additions and 16 deletions
@@ -983,19 +983,19 @@ const float BG_AV_CreaturePos[AV_CPLACE_MAX][4] = {
enum BG_AV_CreatureIds enum BG_AV_CreatureIds
{ {
AV_NPC_A_GRAVEDEFENSE0 = 0, // stormpike Defender AV_NPC_A_TOWERDEFENSE = 0, // stormpike bowman
AV_NPC_A_GRAVEDEFENSE1 = 1, // seasoned defender AV_NPC_A_GRAVEDEFENSE0 = 1, // stormpike Defender
AV_NPC_A_GRAVEDEFENSE2 = 2, // veteran defender AV_NPC_A_GRAVEDEFENSE1 = 2, // seasoned defender
AV_NPC_A_GRAVEDEFENSE3 = 3, // champion defender AV_NPC_A_GRAVEDEFENSE2 = 3, // veteran defender
AV_NPC_A_TOWERDEFENSE = 4, // stormpike bowman AV_NPC_A_GRAVEDEFENSE3 = 4, // champion defender
AV_NPC_A_CAPTAIN = 5, // balinda AV_NPC_A_CAPTAIN = 5, // balinda
AV_NPC_A_BOSS = 6, // vanndar AV_NPC_A_BOSS = 6, // vanndar
AV_NPC_H_GRAVEDEFENSE0 = 7, // frostwolf guardian AV_NPC_H_TOWERDEFENSE = 7, // frostwolf bowman
AV_NPC_H_GRAVEDEFENSE1 = 8, // seasoned guardian AV_NPC_H_GRAVEDEFENSE0 = 8, // frostwolf guardian
AV_NPC_H_GRAVEDEFENSE2 = 9, // veteran guardian AV_NPC_H_GRAVEDEFENSE1 = 9, // seasoned guardian
AV_NPC_H_GRAVEDEFENSE3 = 10, // champion guardian AV_NPC_H_GRAVEDEFENSE2 = 10, // veteran guardian
AV_NPC_H_TOWERDEFENSE = 11, // frostwolf bowman AV_NPC_H_GRAVEDEFENSE3 = 11, // champion guardian
AV_NPC_H_CAPTAIN = 12, // galvangar AV_NPC_H_CAPTAIN = 12, // galvangar
AV_NPC_H_BOSS = 13, // drek thar AV_NPC_H_BOSS = 13, // drek thar
+1 -1
View File
@@ -1689,7 +1689,7 @@ valid examples:
bool foundName = false; bool foundName = false;
for (uint8 dbIndex = LOCALE_koKR; dbIndex < MAX_LOCALE; ++dbIndex) for (uint8 dbIndex = LOCALE_koKR; dbIndex < MAX_LOCALE; ++dbIndex)
{ {
if (dbIndex == -1 || il == NULL || uint8(dbIndex) >= il->Name.size()) if (il == NULL || dbIndex >= il->Name.size())
// using strange database/client combinations can lead to this case // using strange database/client combinations can lead to this case
expectedName = linkedItem->Name1; expectedName = linkedItem->Name1;
else else
+2 -2
View File
@@ -6904,10 +6904,10 @@ bool ChatHandler::HandleInstanceUnbindCommand(const char *args)
if (pDiff) if (pDiff)
diff = atoi(pDiff); diff = atoi(pDiff);
uint16 counter = 0; uint16 counter = 0;
int16 MapId = 0; uint16 MapId = 0;
if (strcmp(pMap, "all")) if (strcmp(pMap, "all"))
if (!(MapId = atoi(pMap))) if (!(MapId = uint16(atoi(pMap))))
return false; return false;
for(uint8 i = 0; i < MAX_DIFFICULTY; ++i) for(uint8 i = 0; i < MAX_DIFFICULTY; ++i)
@@ -928,6 +928,7 @@ bool ConditionMgr::isSourceTypeValid(Condition* cond)
case CONDITION_SOURCE_TYPE_GOSSIP_MENU: case CONDITION_SOURCE_TYPE_GOSSIP_MENU:
case CONDITION_SOURCE_TYPE_GOSSIP_MENU_OPTION: case CONDITION_SOURCE_TYPE_GOSSIP_MENU_OPTION:
case CONDITION_SOURCE_TYPE_NONE: case CONDITION_SOURCE_TYPE_NONE:
default:
break; break;
} }
+1 -2
View File
@@ -16343,8 +16343,7 @@ bool Player::LoadFromDB(uint32 guid, SQLQueryHolder *holder)
m_activeSpec = result->GetUInt8(60); m_activeSpec = result->GetUInt8(60);
// sanity check // sanity check
if (m_specsCount > MAX_TALENT_SPECS || m_activeSpec > MAX_TALENT_SPEC || if (m_specsCount > MAX_TALENT_SPECS || m_activeSpec > MAX_TALENT_SPEC || m_specsCount < MIN_TALENT_SPECS)
m_specsCount < MIN_TALENT_SPECS || m_activeSpec < MIN_TALENT_SPEC)
{ {
m_activeSpec = 0; m_activeSpec = 0;
sLog.outError("Player %s(GUID: %u) has SpecCount = %u and ActiveSpec = %u.", GetName(), GetGUIDLow(), m_specsCount, m_activeSpec); sLog.outError("Player %s(GUID: %u) has SpecCount = %u and ActiveSpec = %u.", GetName(), GetGUIDLow(), m_specsCount, m_activeSpec);
+1 -1
View File
@@ -1683,7 +1683,7 @@ void World::SetInitialWorldSettings()
mail_timer = ((((localtime(&m_gameTime)->tm_hour + 20) % 24)* HOUR * IN_MILLISECONDS) / m_timers[WUPDATE_AUCTIONS].GetInterval()); mail_timer = ((((localtime(&m_gameTime)->tm_hour + 20) % 24)* HOUR * IN_MILLISECONDS) / m_timers[WUPDATE_AUCTIONS].GetInterval());
//1440 //1440
mail_timer_expires = ((DAY * IN_MILLISECONDS) / (m_timers[WUPDATE_AUCTIONS].GetInterval())); mail_timer_expires = ((DAY * IN_MILLISECONDS) / (m_timers[WUPDATE_AUCTIONS].GetInterval()));
sLog.outDebug("Mail timer set to: %u, mail return is called every %u minutes", mail_timer, mail_timer_expires); sLog.outDebug("Mail timer set to: " UI64FMTD ", mail return is called every " UI64FMTD " minutes", uint64(mail_timer), uint64(mail_timer_expires));
///- Initilize static helper structures ///- Initilize static helper structures
AIRegistry::Initialize(); AIRegistry::Initialize();