mirror of
https://github.com/NathanHandley/mod-ah-bot-plus.git
synced 2026-01-13 09:17:21 +00:00
Fix issue where buyer undercuts bids
This commit is contained in:
@@ -770,10 +770,7 @@ void AuctionHouseBot::addNewAuctionBuyerBotBid(Player* AHBplayer, AHBConfig *con
|
||||
bidAmount = auction->GetAuctionOutBid();
|
||||
|
||||
if (auction->bidder)
|
||||
{
|
||||
sAuctionMgr->SendAuctionOutbiddedMail(auction, bidAmount, AHBplayer, trans);
|
||||
CharacterDatabase.CommitTransaction(trans);
|
||||
}
|
||||
|
||||
auction->bidder = AHBplayer->GetGUID();
|
||||
auction->bid = bidAmount;
|
||||
@@ -785,6 +782,8 @@ void AuctionHouseBot::addNewAuctionBuyerBotBid(Player* AHBplayer, AHBConfig *con
|
||||
stmt->SetData(1, auction->bid);
|
||||
stmt->SetData(2, auction->Id);
|
||||
trans->Append(stmt);
|
||||
|
||||
CharacterDatabase.CommitTransaction(trans);
|
||||
}
|
||||
else if (doBuyout)
|
||||
{
|
||||
@@ -815,6 +814,7 @@ void AuctionHouseBot::Update()
|
||||
if (AHCharacters.size() == 0)
|
||||
return;
|
||||
|
||||
|
||||
// Only update if the update cycle has been hit
|
||||
LastCycleCount++;
|
||||
if (LastCycleCount < CyclesBetweenBuyOrSell)
|
||||
|
||||
Reference in New Issue
Block a user