mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-17 07:18:37 +00:00
[Fix] Add check for simultaneous direct vendor and parcel Trader/Buyer Purchase (#4778)
This commit is contained in:
@@ -3786,6 +3786,13 @@ void WorldServer::HandleMessage(uint16 opcode, const EQ::Net::Packet &p)
|
||||
return;
|
||||
}
|
||||
|
||||
if (trader_pc->IsThereACustomer()) {
|
||||
auto customer = entity_list.GetClientByID(trader_pc->GetCustomerID());
|
||||
if (customer) {
|
||||
customer->CancelTraderTradeWindow();
|
||||
}
|
||||
}
|
||||
|
||||
auto item_sn = Strings::ToUnsignedBigInt(in->trader_buy_struct.serial_number);
|
||||
auto outapp = std::make_unique<EQApplicationPacket>(OP_Trader, sizeof(TraderBuy_Struct));
|
||||
auto data = (TraderBuy_Struct *) outapp->pBuffer;
|
||||
@@ -3981,6 +3988,12 @@ void WorldServer::HandleMessage(uint16 opcode, const EQ::Net::Packet &p)
|
||||
worldserver.SendPacket(pack);
|
||||
return;
|
||||
}
|
||||
if (buyer->IsThereACustomer()) {
|
||||
auto customer = entity_list.GetClientByID(buyer->GetCustomerID());
|
||||
if (customer) {
|
||||
customer->CancelBuyerTradeWindow();
|
||||
}
|
||||
}
|
||||
|
||||
BuyerLineSellItem_Struct sell_line{};
|
||||
sell_line.item_id = in->buy_item_id;
|
||||
|
||||
Reference in New Issue
Block a user