aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Globals/ObjectMgr.cpp
diff options
context:
space:
mode:
authorNay <dnpd.dd@gmail.com>2012-03-27 21:36:16 +0100
committerNay <dnpd.dd@gmail.com>2012-03-27 21:36:16 +0100
commit729f419af10f3fbac0d77319f7244bfbe2a443c0 (patch)
tree39a0fd6477ca22f5961bc7a83294f8c150a872ee /src/server/game/Globals/ObjectMgr.cpp
parent8e87fe27443213ca3c312cf8078a44403542aa75 (diff)
Core/DBLayer: Correct few more wrong read types (No. 4)
DB/World: Some consistency in the ints "length" field (not really a length) All world dbs checked
Diffstat (limited to 'src/server/game/Globals/ObjectMgr.cpp')
-rwxr-xr-xsrc/server/game/Globals/ObjectMgr.cpp26
1 files changed, 14 insertions, 12 deletions
diff --git a/src/server/game/Globals/ObjectMgr.cpp b/src/server/game/Globals/ObjectMgr.cpp
index 63a02378787..2a92a437d72 100755
--- a/src/server/game/Globals/ObjectMgr.cpp
+++ b/src/server/game/Globals/ObjectMgr.cpp
@@ -2804,6 +2804,7 @@ void ObjectMgr::LoadVehicleTemplateAccessories()
uint32 count = 0;
+ // 0 1 2 3 4 5
QueryResult result = WorldDatabase.Query("SELECT `entry`, `accessory_entry`, `seat_id`, `minion`, `summontype`, `summontimer` FROM `vehicle_template_accessory`");
if (!result)
@@ -2860,6 +2861,7 @@ void ObjectMgr::LoadVehicleAccessories()
uint32 count = 0;
+ // 0 1 2 3 4 5
QueryResult result = WorldDatabase.Query("SELECT `guid`, `accessory_entry`, `seat_id`, `minion`, `summontype`, `summontimer` FROM `vehicle_accessory`");
if (!result)
@@ -6753,7 +6755,7 @@ void ObjectMgr::LoadReputationRewardRate()
_repRewardRateStore.clear(); // for reload case
- uint32 count = 0;
+ uint32 count = 0; // 0 1 2 3
QueryResult result = WorldDatabase.Query("SELECT faction, quest_rate, creature_rate, spell_rate FROM reputation_reward_rate");
if (!result)
@@ -6890,7 +6892,7 @@ void ObjectMgr::LoadReputationSpilloverTemplate()
_repSpilloverTemplateStore.clear(); // for reload case
- uint32 count = 0;
+ uint32 count = 0; // 0 1 2 3 4 5 6 7 8 9 10 11 12
QueryResult result = WorldDatabase.Query("SELECT faction, faction1, rate_1, rank_1, faction2, rate_2, rank_2, faction3, rate_3, rank_3, faction4, rate_4, rank_4 FROM reputation_spillover_template");
if (!result)
@@ -6904,22 +6906,22 @@ void ObjectMgr::LoadReputationSpilloverTemplate()
{
Field* fields = result->Fetch();
- uint32 factionId = fields[0].GetUInt32();
+ uint32 factionId = fields[0].GetUInt16();
RepSpilloverTemplate repTemplate;
- repTemplate.faction[0] = fields[1].GetUInt32();
+ repTemplate.faction[0] = fields[1].GetUInt16();
repTemplate.faction_rate[0] = fields[2].GetFloat();
- repTemplate.faction_rank[0] = fields[3].GetUInt32();
- repTemplate.faction[1] = fields[4].GetUInt32();
+ repTemplate.faction_rank[0] = fields[3].GetUInt8();
+ repTemplate.faction[1] = fields[4].GetUInt16();
repTemplate.faction_rate[1] = fields[5].GetFloat();
- repTemplate.faction_rank[1] = fields[6].GetUInt32();
- repTemplate.faction[2] = fields[7].GetUInt32();
+ repTemplate.faction_rank[1] = fields[6].GetUInt8();
+ repTemplate.faction[2] = fields[7].GetUInt16();
repTemplate.faction_rate[2] = fields[8].GetFloat();
- repTemplate.faction_rank[2] = fields[9].GetUInt32();
- repTemplate.faction[3] = fields[10].GetUInt32();
+ repTemplate.faction_rank[2] = fields[9].GetUInt8();
+ repTemplate.faction[3] = fields[10].GetUInt16();
repTemplate.faction_rate[3] = fields[11].GetFloat();
- repTemplate.faction_rank[3] = fields[12].GetUInt32();
+ repTemplate.faction_rank[3] = fields[12].GetUInt8();
FactionEntry const* factionEntry = sFactionStore.LookupEntry(factionId);
@@ -7806,7 +7808,7 @@ void ObjectMgr::LoadFishingBaseSkillLevel()
{
Field* fields = result->Fetch();
uint32 entry = fields[0].GetUInt32();
- int32 skill = fields[1].GetInt32();
+ int32 skill = fields[1].GetInt16();
AreaTableEntry const* fArea = GetAreaEntryByAreaID(entry);
if (!fArea)