From 4fae0e866646de40ec68592190785cdfd8f6b62d Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 20 May 2015 19:14:48 +0300 Subject: eathena: impliment packet CMSG_GUILD_OPPOSITION. --- src/net/eathena/guildhandler.cpp | 9 +++++++++ src/net/eathena/guildhandler.h | 2 ++ src/net/guildhandler.h | 2 ++ src/net/tmwa/guildhandler.cpp | 4 ++++ src/net/tmwa/guildhandler.h | 2 ++ 5 files changed, 19 insertions(+) diff --git a/src/net/eathena/guildhandler.cpp b/src/net/eathena/guildhandler.cpp index 84dd8eec8..350eb3bed 100644 --- a/src/net/eathena/guildhandler.cpp +++ b/src/net/eathena/guildhandler.cpp @@ -492,4 +492,13 @@ void GuildHandler::changePostionInfo(const int posId, outMsg.writeString(name, 24, "name"); } +void GuildHandler::requestOpposition(const Being *const being) const +{ + if (!being) + return; + + createOutPacket(CMSG_GUILD_OPPOSITION); + outMsg.writeInt32(being->getId(), "account id"); +} + } // namespace EAthena diff --git a/src/net/eathena/guildhandler.h b/src/net/eathena/guildhandler.h index 6f42b4e80..d7406c2b6 100644 --- a/src/net/eathena/guildhandler.h +++ b/src/net/eathena/guildhandler.h @@ -84,6 +84,8 @@ class GuildHandler final : public Ea::GuildHandler, public MessageHandler const int payRate, const std::string &name) const override final; + void requestOpposition(const Being *const being) const override final; + protected: static void processGuildUpdateCoords(Net::MessageIn &msg); diff --git a/src/net/guildhandler.h b/src/net/guildhandler.h index 576e486a4..0a1474631 100644 --- a/src/net/guildhandler.h +++ b/src/net/guildhandler.h @@ -69,6 +69,8 @@ class GuildHandler notfinal virtual void requestAlliance(const Being *const being) const = 0; + virtual void requestOpposition(const Being *const being) const = 0; + virtual void requestAllianceResponse(const int beingId, const bool accept) const = 0; diff --git a/src/net/tmwa/guildhandler.cpp b/src/net/tmwa/guildhandler.cpp index d9a1f6b7f..ab4820927 100644 --- a/src/net/tmwa/guildhandler.cpp +++ b/src/net/tmwa/guildhandler.cpp @@ -443,4 +443,8 @@ void GuildHandler::changePostionInfo(const int posId A_UNUSED, { } +void GuildHandler::requestOpposition(const Being *const being A_UNUSED) const +{ +} + } // namespace TmwAthena diff --git a/src/net/tmwa/guildhandler.h b/src/net/tmwa/guildhandler.h index 6b464d856..f4d803c3c 100644 --- a/src/net/tmwa/guildhandler.h +++ b/src/net/tmwa/guildhandler.h @@ -84,6 +84,8 @@ class GuildHandler final : public Ea::GuildHandler, public MessageHandler const int payRate, const std::string &name) const override final; + void requestOpposition(const Being *const being) const override final; + protected: static void processGuildPositionInfo(Net::MessageIn &msg); -- cgit v1.2.3-70-g09d2