diff options
author | Andrei Karas <akaras@inbox.ru> | 2015-09-02 20:58:41 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2015-09-02 20:58:41 +0300 |
commit | 84d2bab38202cd52b5eb0a37c12204ab6f607915 (patch) | |
tree | 2f3951b2f4f3b75f190eb2539979cc4afbace27c /src/net/tmwa/tradehandler.cpp | |
parent | 40730c4fa73d403cf7284a76d9b26f7ec662afa4 (diff) | |
download | manaplus-84d2bab38202cd52b5eb0a37c12204ab6f607915.tar.gz manaplus-84d2bab38202cd52b5eb0a37c12204ab6f607915.tar.bz2 manaplus-84d2bab38202cd52b5eb0a37c12204ab6f607915.tar.xz manaplus-84d2bab38202cd52b5eb0a37c12204ab6f607915.zip |
Remove MessageHandler class
Diffstat (limited to 'src/net/tmwa/tradehandler.cpp')
-rw-r--r-- | src/net/tmwa/tradehandler.cpp | 53 |
1 files changed, 0 insertions, 53 deletions
diff --git a/src/net/tmwa/tradehandler.cpp b/src/net/tmwa/tradehandler.cpp index 35a1c06eb..3eccd966d 100644 --- a/src/net/tmwa/tradehandler.cpp +++ b/src/net/tmwa/tradehandler.cpp @@ -54,64 +54,11 @@ namespace TmwAthena { TradeHandler::TradeHandler() : - MessageHandler(), Ea::TradeHandler() { - static const uint16_t _messages[] = - { - SMSG_TRADE_REQUEST, - SMSG_TRADE_RESPONSE, - SMSG_TRADE_ITEM_ADD, - SMSG_TRADE_ITEM_ADD_RESPONSE, - SMSG_TRADE_OK, - SMSG_TRADE_CANCEL, - SMSG_TRADE_COMPLETE, - 0 - }; - handledMessages = _messages; tradeHandler = this; } - -void TradeHandler::handleMessage(Net::MessageIn &msg) -{ - BLOCK_START("TradeHandler::handleMessage") - switch (msg.getId()) - { - case SMSG_TRADE_REQUEST: - TradeRecv::processTradeRequest(msg); - break; - - case SMSG_TRADE_RESPONSE: - TradeRecv::processTradeResponse(msg); - break; - - case SMSG_TRADE_ITEM_ADD: - TradeRecv::processTradeItemAdd(msg); - break; - - case SMSG_TRADE_ITEM_ADD_RESPONSE: - TradeRecv::processTradeItemAddResponse(msg); - break; - - case SMSG_TRADE_OK: - Ea::TradeRecv::processTradeOk(msg); - break; - - case SMSG_TRADE_CANCEL: - Ea::TradeRecv::processTradeCancel(msg); - break; - - case SMSG_TRADE_COMPLETE: - Ea::TradeRecv::processTradeComplete(msg); - break; - - default: - break; - } - BLOCK_END("TradeHandler::handleMessage") -} - void TradeHandler::request(const Being *const being) const { if (!being) |