mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-16 22:58:34 +00:00
Added trade hack detection code
This commit is contained in:
+20
-1
@@ -13287,7 +13287,6 @@ void Client::Handle_OP_TradeAcceptClick(const EQApplicationPacket *app)
|
||||
other->trade->state = TradeCompleting;
|
||||
trade->state = TradeCompleting;
|
||||
|
||||
// should we do this for NoDrop items as well?
|
||||
if (CheckTradeLoreConflict(other) || other->CheckTradeLoreConflict(this)) {
|
||||
Message_StringID(13, TRADE_CANCEL_LORE);
|
||||
other->Message_StringID(13, TRADE_CANCEL_LORE);
|
||||
@@ -13296,6 +13295,26 @@ void Client::Handle_OP_TradeAcceptClick(const EQApplicationPacket *app)
|
||||
other->trade->Reset();
|
||||
trade->Reset();
|
||||
}
|
||||
else if (CheckTradeNonDroppable()) {
|
||||
Message_StringID(13, TRADE_HAS_BEEN_CANCELLED);
|
||||
other->Message_StringID(13, TRADE_HAS_BEEN_CANCELLED);
|
||||
this->FinishTrade(this);
|
||||
other->FinishTrade(other);
|
||||
other->trade->Reset();
|
||||
trade->Reset();
|
||||
Message(15, "Hacking activity detected in trade transaction.");
|
||||
// TODO: query (this) as a hacker
|
||||
}
|
||||
else if (other->CheckTradeNonDroppable()) {
|
||||
Message_StringID(13, TRADE_HAS_BEEN_CANCELLED);
|
||||
other->Message_StringID(13, TRADE_HAS_BEEN_CANCELLED);
|
||||
this->FinishTrade(this);
|
||||
other->FinishTrade(other);
|
||||
other->trade->Reset();
|
||||
trade->Reset();
|
||||
other->Message(15, "Hacking activity detected in trade transaction.");
|
||||
// TODO: query (other) as a hacker
|
||||
}
|
||||
else {
|
||||
// Audit trade to database for both trade streams
|
||||
other->trade->LogTrade();
|
||||
|
||||
Reference in New Issue
Block a user