mirror of
https://github.com/NathanHandley/mod-ah-bot-plus.git
synced 2026-01-13 01:08:37 +00:00
Merge pull request #12 from NathanHandley/BotSellRework
Disabled database-based disabled item store
This commit is contained in:
@@ -96,6 +96,12 @@ void AuctionHouseBot::calculateItemValue(ItemTemplate const* itemProto, uint64&
|
|||||||
outBuyoutPrice = urand(500, 1500);
|
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
|
// Multiply the price based on quality
|
||||||
switch (itemProto->Quality)
|
switch (itemProto->Quality)
|
||||||
{
|
{
|
||||||
@@ -726,16 +732,19 @@ void AuctionHouseBot::Update()
|
|||||||
void AuctionHouseBot::Initialize()
|
void AuctionHouseBot::Initialize()
|
||||||
{
|
{
|
||||||
DisableItemStore.clear();
|
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)
|
//if (result)
|
||||||
{
|
//{
|
||||||
do
|
// do
|
||||||
{
|
// {
|
||||||
Field* fields = result->Fetch();
|
// Field* fields = result->Fetch();
|
||||||
DisableItemStore.insert(fields[0].Get<uint32>());
|
// DisableItemStore.insert(fields[0].Get<uint32>());
|
||||||
} while (result->NextRow());
|
// } while (result->NextRow());
|
||||||
}
|
//}
|
||||||
|
DisableItemStore.insert(51809); // Portable Hole
|
||||||
|
DisableItemStore.insert(38082); // Gigantique Bag
|
||||||
|
|
||||||
//End Filters
|
//End Filters
|
||||||
if (!sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_INTERACTION_AUCTION))
|
if (!sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_INTERACTION_AUCTION))
|
||||||
|
|||||||
Reference in New Issue
Block a user