Core/DBLayer: Even more types fixes...

This commit is contained in:
Nay
2012-03-29 15:08:17 +01:00
parent f80f94809c
commit 92d3548f0b
6 changed files with 9 additions and 9 deletions
@@ -38,7 +38,7 @@ void CreatureEventAIMgr::LoadCreatureEventAI_Texts()
// Load EventAI Text
sObjectMgr->LoadTrinityStrings("creature_ai_texts", MIN_CREATURE_AI_TEXT_STRING_ID, MAX_CREATURE_AI_TEXT_STRING_ID);
// Gather Additional data from EventAI Texts
// Gather Additional data from EventAI Texts 0 1 2 3 4
QueryResult result = WorldDatabase.Query("SELECT entry, sound, type, language, emote FROM creature_ai_texts");
if (!result)
+2 -2
View File
@@ -5120,7 +5120,7 @@ void Player::DeleteOldCharacters(uint32 keepDays)
do
{
Field* fields = result->Fetch();
Player::DeleteFromDB(fields[0].GetUInt64(), fields[1].GetUInt32(), true, true);
Player::DeleteFromDB(fields[0].GetUInt32(), fields[1].GetUInt32(), true, true);
}
while (result->NextRow());
}
@@ -17904,7 +17904,7 @@ void Player::_LoadMail()
m->deliver_time = time_t(fields[8].GetUInt32());
m->money = fields[9].GetUInt32();
m->COD = fields[10].GetUInt32();
m->checked = fields[11].GetUInt32();
m->checked = fields[11].GetUInt8();
m->stationery = fields[12].GetUInt8();
m->mailTemplateId = fields[13].GetInt16();
+1 -1
View File
@@ -5317,7 +5317,7 @@ void ObjectMgr::ReturnOrDeleteOldMails(bool serverUp)
std::map<uint32 /*messageId*/, MailItemInfoVec> itemsCache;
stmt = CharacterDatabase.GetPreparedStatement(CHAR_SEL_EXPIRED_MAIL_ITEMS);
stmt->setUInt64(0, basetime);
stmt->setUInt32(0, (uint32)basetime);
if (PreparedQueryResult items = CharacterDatabase.Query(stmt))
{
MailItemInfo item;
+3 -3
View File
@@ -215,10 +215,10 @@ void GroupMgr::LoadGroups()
Group* group = GetGroupByDbStoreId(fields[0].GetUInt32());
// group will never be NULL (we have run consistency sql's before loading)
MapEntry const* mapEntry = sMapStore.LookupEntry(fields[1].GetUInt32());
MapEntry const* mapEntry = sMapStore.LookupEntry(fields[1].GetUInt16());
if (!mapEntry || !mapEntry->IsDungeon())
{
sLog->outErrorDb("Incorrect entry in group_instance table : no dungeon map %d", fields[1].GetUInt32());
sLog->outErrorDb("Incorrect entry in group_instance table : no dungeon map %d", fields[1].GetUInt16());
continue;
}
@@ -229,7 +229,7 @@ void GroupMgr::LoadGroups()
diff = 0; // default for both difficaly types
}
InstanceSave* save = sInstanceSaveMgr->AddInstanceSave(mapEntry->MapID, fields[2].GetUInt32(), Difficulty(diff), time_t(fields[5].GetUInt64()), fields[6].GetBool(), true);
InstanceSave* save = sInstanceSaveMgr->AddInstanceSave(mapEntry->MapID, fields[2].GetUInt32(), Difficulty(diff), time_t(fields[5].GetUInt64()), (bool)fields[6].GetUInt64(), true);
group->BindToInstance(save, fields[3].GetBool(), true);
++count;
}
+1 -1
View File
@@ -521,7 +521,7 @@ void ReputationMgr::LoadFromDB(PreparedQueryResult result)
FactionState* faction = &_factions[factionEntry->reputationListID];
// update standing to current
faction->Standing = int32(fields[1].GetUInt32());
faction->Standing = fields[1].GetInt32();
// update counters
int32 BaseRep = GetBaseReputation(factionEntry);
+1 -1
View File
@@ -2934,7 +2934,7 @@ void World::LoadCharacterNameData()
do
{
Field *fields = result->Fetch();
Field* fields = result->Fetch();
AddCharacterNameData(fields[0].GetUInt32(), fields[1].GetString(),
fields[3].GetUInt8() /*gender*/, fields[2].GetUInt8() /*race*/, fields[4].GetUInt8() /*class*/);
++count;