From cc19f13863bc331e8e7a34f850370fc3bd32826a Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 29 Mar 2015 13:42:39 +0300 Subject: eathena: add packet CMSG_BATTLE_REGISTER 0x08d7. --- src/net/eathena/battlegroundhandler.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/net/eathena/battlegroundhandler.cpp') diff --git a/src/net/eathena/battlegroundhandler.cpp b/src/net/eathena/battlegroundhandler.cpp index fa5bbf1aa..91078e141 100644 --- a/src/net/eathena/battlegroundhandler.cpp +++ b/src/net/eathena/battlegroundhandler.cpp @@ -22,6 +22,7 @@ #include "logger.h" +#include "net/eathena/messageout.h" #include "net/eathena/protocol.h" #include "debug.h" @@ -150,4 +151,12 @@ void BattleGroundHandler::processBattleJoined(Net::MessageIn &msg) msg.readInt32("position"); } +void BattleGroundHandler::registerBg(const BattleGroundType::Type &type, + const std::string &name) const +{ + createOutPacket(CMSG_BATTLE_REGISTER); + outMsg.writeInt16(static_cast(type), "type"); + outMsg.writeString(name, 24, "bg name"); +} + } // namespace EAthena -- cgit v1.2.3-70-g09d2