From f49ff6e34d8a1715b3f669ca45db2814f0ce25d5 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 18 Mar 2015 16:39:39 +0300 Subject: eathena: add partial support for packet SMSG_BATTLE_BEGINS 0x08df. --- src/net/eathena/battlegroundhandler.cpp | 12 ++++++++++++ src/net/eathena/battlegroundhandler.h | 2 ++ src/net/eathena/packets.h | 2 +- src/net/eathena/protocol.h | 1 + 4 files changed, 16 insertions(+), 1 deletion(-) (limited to 'src/net') diff --git a/src/net/eathena/battlegroundhandler.cpp b/src/net/eathena/battlegroundhandler.cpp index 0b6d4c17d..9672ab94e 100644 --- a/src/net/eathena/battlegroundhandler.cpp +++ b/src/net/eathena/battlegroundhandler.cpp @@ -42,6 +42,7 @@ BattleGroundHandler::BattleGroundHandler() : SMSG_BATTLE_UPDATE_COORDS, SMSG_BATTLE_PLAY, SMSG_BATTLE_QUEUE_ACK, + SMSG_BATTLE_BEGINS, 0 }; handledMessages = _messages; @@ -72,6 +73,10 @@ void BattleGroundHandler::handleMessage(Net::MessageIn &msg) processBattleQueueAck(msg); break; + case SMSG_BATTLE_BEGINS: + processBattleBegins(msg); + break; + default: break; } @@ -115,4 +120,11 @@ void BattleGroundHandler::processBattleQueueAck(Net::MessageIn &msg) msg.readString(24, "bg name"); } +void BattleGroundHandler::processBattleBegins(Net::MessageIn &msg) +{ + UNIMPLIMENTEDPACKET; + msg.readString(24, "bg name"); + msg.readString(24, "game name"); +} + } // namespace EAthena diff --git a/src/net/eathena/battlegroundhandler.h b/src/net/eathena/battlegroundhandler.h index a17ba4ff3..1fa9d4236 100644 --- a/src/net/eathena/battlegroundhandler.h +++ b/src/net/eathena/battlegroundhandler.h @@ -49,6 +49,8 @@ class BattleGroundHandler final : public MessageHandler, void processBattlePlay(Net::MessageIn &msg); void processBattleQueueAck(Net::MessageIn &msg); + + void processBattleBegins(Net::MessageIn &msg); }; } // namespace EAthena diff --git a/src/net/eathena/packets.h b/src/net/eathena/packets.h index 0988e1390..6adf467ef 100644 --- a/src/net/eathena/packets.h +++ b/src/net/eathena/packets.h @@ -231,7 +231,7 @@ int16_t packet_lengths[] = 0, 0, 0, -1, 0, 0, 0, 0, 0, 12, 10, 0, 0, 0, 0, 0, // #0x08C0 -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 10, - 0, 0, 10, 0, 0, -1, 6, 0, 27, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 10, 0, 0, -1, 6, 0, 27, 0, 0, 0, 0, 0, 0, 50, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, //0 1 2 3 4 5 6 7 8 9 a b c d e f diff --git a/src/net/eathena/protocol.h b/src/net/eathena/protocol.h index 80351a38e..d851b1081 100644 --- a/src/net/eathena/protocol.h +++ b/src/net/eathena/protocol.h @@ -445,6 +445,7 @@ #define SMSG_BATTLE_UPDATE_COORDS 0x02df #define SMSG_BATTLE_PLAY 0x07fe #define SMSG_BATTLE_QUEUE_ACK 0x08d8 +#define SMSG_BATTLE_BEGINS 0x08df /********************************** * Packets from client to server * -- cgit v1.2.3-70-g09d2