aboutsummaryrefslogtreecommitdiff
path: root/src/game/ObjectMgr.cpp
diff options
context:
space:
mode:
authorSpp <none@none>2010-04-19 17:08:08 +0200
committerSpp <none@none>2010-04-19 17:08:08 +0200
commit97b7aa111691d8545e1b6666c23251f20e61a8d9 (patch)
tree143227afb247d0adfd1b7bc9bc74dce72478a5c5 /src/game/ObjectMgr.cpp
parent452cada8b63e3a894fe75e1700c56e5ce3a79301 (diff)
Remove unused columns from sqls
--HG-- branch : trunk
Diffstat (limited to 'src/game/ObjectMgr.cpp')
-rw-r--r--src/game/ObjectMgr.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/game/ObjectMgr.cpp b/src/game/ObjectMgr.cpp
index 0ce50659fb1..cffb81253a3 100644
--- a/src/game/ObjectMgr.cpp
+++ b/src/game/ObjectMgr.cpp
@@ -8252,7 +8252,7 @@ void ObjectMgr::LoadTrainerSpell()
int ObjectMgr::LoadReferenceVendor(int32 vendor, int32 item, std::set<uint32> *skip_vendors)
{
// find all items from the reference vendor
- QueryResult_AutoPtr result = WorldDatabase.PQuery("SELECT entry, item, maxcount, incrtime, ExtendedCost FROM npc_vendor WHERE entry='%d'", item);
+ QueryResult_AutoPtr result = WorldDatabase.PQuery("SELECT item, maxcount, incrtime, ExtendedCost FROM npc_vendor WHERE entry='%d'", item);
if (!result)
{
barGoLink bar(1);
@@ -8269,17 +8269,16 @@ int ObjectMgr::LoadReferenceVendor(int32 vendor, int32 item, std::set<uint32> *s
bar.step();
Field* fields = result->Fetch();
- uint32 entry = fields[0].GetUInt32();
- int32 item_id = fields[1].GetInt32();
+ int32 item_id = fields[0].GetInt32();
// if item is a negative, its a reference
if (item_id < 0)
count += LoadReferenceVendor(vendor, -item_id, skip_vendors);
else
{
- int32 maxcount = fields[2].GetInt32();
- uint32 incrtime = fields[3].GetUInt32();
- uint32 ExtendedCost = fields[4].GetUInt32();
+ int32 maxcount = fields[1].GetInt32();
+ uint32 incrtime = fields[2].GetUInt32();
+ uint32 ExtendedCost = fields[3].GetUInt32();
if (!IsVendorItemValid(vendor,item_id,maxcount,incrtime,ExtendedCost,NULL,skip_vendors))
continue;