mirror of
https://github.com/azerothcore/mod-ale
synced 2025-11-29 15:38:17 +08:00
use auctionHouseEntry for all auctions hooks add buyout, etime to AUCTION_EVENT_ON_ADD
Signed-off-by: Salja <salja8840@gmail.com>
This commit is contained in:
@@ -82,47 +82,49 @@ void Eluna::OnChange(Weather* weather, uint32 zone, WeatherState state, float gr
|
||||
}
|
||||
|
||||
// Auction House
|
||||
void Eluna::OnAdd(AuctionHouseObject* ah, Player* pPlayer, Item* pItem)
|
||||
void Eluna::OnAdd(AuctionHouseEntry const* auctionHouseEntry, Player* pPlayer, Item* pItem, uint32 buyout, uint32 etime)
|
||||
{
|
||||
if (!ServerEventBindings->HasEvents(AUCTION_EVENT_ON_ADD))
|
||||
return;
|
||||
|
||||
LOCK_ELUNA;
|
||||
Push(ah);
|
||||
Push(auctionHouseEntry);
|
||||
Push(pPlayer);
|
||||
Push(pItem);
|
||||
Push(buyout);
|
||||
Push(etime);
|
||||
CallAllFunctions(ServerEventBindings, AUCTION_EVENT_ON_ADD);
|
||||
}
|
||||
|
||||
void Eluna::OnRemove(AuctionHouseObject* ah, Player* pPlayer, Item* pItem)
|
||||
void Eluna::OnRemove(AuctionHouseEntry const* auctionHouseEntry, Player* pPlayer, Item* pItem)
|
||||
{
|
||||
if (!ServerEventBindings->HasEvents(AUCTION_EVENT_ON_REMOVE))
|
||||
return;
|
||||
|
||||
LOCK_ELUNA;
|
||||
Push(ah);
|
||||
Push(auctionHouseEntry);
|
||||
Push(pPlayer);
|
||||
Push(pItem);
|
||||
CallAllFunctions(ServerEventBindings, AUCTION_EVENT_ON_REMOVE);
|
||||
}
|
||||
|
||||
void Eluna::OnSuccessful(AuctionHouseObject* ah)
|
||||
void Eluna::OnSuccessful(AuctionHouseEntry const* auctionHouseEntry)
|
||||
{
|
||||
if (!ServerEventBindings->HasEvents(AUCTION_EVENT_ON_SUCCESSFUL))
|
||||
return;
|
||||
|
||||
LOCK_ELUNA;
|
||||
Push(ah);
|
||||
Push(auctionHouseEntry);
|
||||
CallAllFunctions(ServerEventBindings, AUCTION_EVENT_ON_SUCCESSFUL);
|
||||
}
|
||||
|
||||
void Eluna::OnExpire(AuctionHouseObject* ah)
|
||||
void Eluna::OnExpire(AuctionHouseEntry const* auctionHouseEntry)
|
||||
{
|
||||
if (!ServerEventBindings->HasEvents(AUCTION_EVENT_ON_EXPIRE))
|
||||
return;
|
||||
|
||||
LOCK_ELUNA;
|
||||
Push(ah);
|
||||
Push(auctionHouseEntry);
|
||||
CallAllFunctions(ServerEventBindings, AUCTION_EVENT_ON_EXPIRE);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user