From 214052b45a31e4e1c966ad20ea277df08300a1ee Mon Sep 17 00:00:00 2001 From: NathanHandley Date: Mon, 27 Nov 2023 21:43:32 -0600 Subject: [PATCH] Disabled database-based disabled item store --- src/AuctionHouseBot.cpp | 27 ++++++++++++++++++--------- 1 file changed, 18 insertions(+), 9 deletions(-) diff --git a/src/AuctionHouseBot.cpp b/src/AuctionHouseBot.cpp index 4f16c8a..8a8035f 100644 --- a/src/AuctionHouseBot.cpp +++ b/src/AuctionHouseBot.cpp @@ -96,6 +96,12 @@ void AuctionHouseBot::calculateItemValue(ItemTemplate const* itemProto, uint64& outBuyoutPrice = urand(500, 1500); } + // If still no buy price, give it something low + if (outBuyoutPrice == 0) + { + outBuyoutPrice = urand(500, 1500); + } + // Multiply the price based on quality switch (itemProto->Quality) { @@ -726,16 +732,19 @@ void AuctionHouseBot::Update() void AuctionHouseBot::Initialize() { DisableItemStore.clear(); - QueryResult result = WorldDatabase.Query("SELECT item FROM mod_auctionhousebot_disabled_items"); + // No longer make this a database thing + //QueryResult result = WorldDatabase.Query("SELECT item FROM mod_auctionhousebot_disabled_items"); - if (result) - { - do - { - Field* fields = result->Fetch(); - DisableItemStore.insert(fields[0].Get()); - } while (result->NextRow()); - } + //if (result) + //{ + // do + // { + // Field* fields = result->Fetch(); + // DisableItemStore.insert(fields[0].Get()); + // } while (result->NextRow()); + //} + DisableItemStore.insert(51809); // Portable Hole + DisableItemStore.insert(38082); // Gigantique Bag //End Filters if (!sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_INTERACTION_AUCTION))