summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-10-14 15:35:23 +0300
committerAndrei Karas <akaras@inbox.ru>2014-10-14 15:35:23 +0300
commitf201143f1896adc0b94cd62b5f28b9b7bfe5fb39 (patch)
treee081e55986a245dd5b3ae134147a5f4c1c1b07be /src
parent4cfe79cad811756d59ee5dcf12f4382a88791c3a (diff)
downloadmv-f201143f1896adc0b94cd62b5f28b9b7bfe5fb39.tar.gz
mv-f201143f1896adc0b94cd62b5f28b9b7bfe5fb39.tar.bz2
mv-f201143f1896adc0b94cd62b5f28b9b7bfe5fb39.tar.xz
mv-f201143f1896adc0b94cd62b5f28b9b7bfe5fb39.zip
Add empty elementalhandler.
Diffstat (limited to 'src')
-rw-r--r--src/CMakeLists.txt5
-rw-r--r--src/Makefile.am5
-rw-r--r--src/net/eathena/elementalhandler.cpp50
-rw-r--r--src/net/eathena/elementalhandler.h43
-rw-r--r--src/net/eathena/generalhandler.cpp5
-rw-r--r--src/net/eathena/generalhandler.h1
-rw-r--r--src/net/elementalhandler.h42
-rw-r--r--src/net/net.cpp2
-rw-r--r--src/net/tmwa/elementalhandler.cpp50
-rw-r--r--src/net/tmwa/elementalhandler.h43
-rw-r--r--src/net/tmwa/generalhandler.cpp5
-rw-r--r--src/net/tmwa/generalhandler.h1
12 files changed, 250 insertions, 2 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 8578634f3..5fe7616c9 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -531,6 +531,7 @@ SET(SRCS
net/charserverhandler.cpp
net/charserverhandler.h
net/chathandler.h
+ net/elementalhandler.h
net/download.cpp
net/download.h
net/downloadstatus.h
@@ -1312,6 +1313,8 @@ SET(SRCS_TMWA
net/tmwa/charserverhandler.h
net/tmwa/chathandler.cpp
net/tmwa/chathandler.h
+ net/tmwa/elementalhandler.cpp
+ net/tmwa/elementalhandler.h
net/tmwa/familyhandler.cpp
net/tmwa/familyhandler.h
net/tmwa/friendshandler.cpp
@@ -1383,6 +1386,8 @@ SET(SRCS_EATHENA
net/eathena/charserverhandler.h
net/eathena/chathandler.cpp
net/eathena/chathandler.h
+ net/eathena/elementalhandler.cpp
+ net/eathena/elementalhandler.h
net/eathena/familyhandler.cpp
net/eathena/familyhandler.h
net/eathena/friendshandler.cpp
diff --git a/src/Makefile.am b/src/Makefile.am
index 91bd4b4db..b79cbe16d 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -653,6 +653,7 @@ manaplus_SOURCES += gui/widgets/avatarlistbox.cpp \
net/charserverhandler.cpp \
net/charserverhandler.h \
net/chathandler.h \
+ net/elementalhandler.h \
net/familyhandler.h \
net/friendshandler.h \
net/download.cpp \
@@ -1246,6 +1247,8 @@ manaplus_SOURCES += \
net/tmwa/charserverhandler.h \
net/tmwa/chathandler.cpp \
net/tmwa/chathandler.h \
+ net/tmwa/elementalhandler.cpp \
+ net/tmwa/elementalhandler.h \
net/tmwa/familyhandler.cpp \
net/tmwa/familyhandler.h \
net/tmwa/friendshandler.cpp \
@@ -1318,6 +1321,8 @@ manaplus_SOURCES += net/eathena/adminhandler.cpp \
net/eathena/charserverhandler.h \
net/eathena/chathandler.cpp \
net/eathena/chathandler.h \
+ net/eathena/elementalhandler.cpp \
+ net/eathena/elementalhandler.h \
net/eathena/familyhandler.cpp \
net/eathena/familyhandler.h \
net/eathena/friendshandler.cpp \
diff --git a/src/net/eathena/elementalhandler.cpp b/src/net/eathena/elementalhandler.cpp
new file mode 100644
index 000000000..9e4f77c0c
--- /dev/null
+++ b/src/net/eathena/elementalhandler.cpp
@@ -0,0 +1,50 @@
+/*
+ * The ManaPlus Client
+ * Copyright (C) 2011-2014 The ManaPlus Developers
+ *
+ * This file is part of The ManaPlus Client.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include "net/eathena/elementalhandler.h"
+
+#include "debug.h"
+
+extern Net::ElementalHandler *elementalHandler;
+
+namespace EAthena
+{
+
+ElementalHandler::ElementalHandler() :
+ MessageHandler()
+{
+ static const uint16_t _messages[] =
+ {
+ 0
+ };
+ handledMessages = _messages;
+ elementalHandler = this;
+}
+
+void ElementalHandler::handleMessage(Net::MessageIn &msg)
+{
+ switch (msg.getId())
+ {
+ default:
+ break;
+ }
+}
+
+} // namespace EAthena
diff --git a/src/net/eathena/elementalhandler.h b/src/net/eathena/elementalhandler.h
new file mode 100644
index 000000000..13f4d259b
--- /dev/null
+++ b/src/net/eathena/elementalhandler.h
@@ -0,0 +1,43 @@
+/*
+ * The ManaPlus Client
+ * Copyright (C) 2011-2014 The ManaPlus Developers
+ *
+ * This file is part of The ManaPlus Client.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#ifndef NET_EATHENA_ELEMENTALHANDLER_H
+#define NET_EATHENA_ELEMENTALHANDLER_H
+
+#include "net/elementalhandler.h"
+
+#include "net/eathena/messagehandler.h"
+
+namespace EAthena
+{
+class ElementalHandler final : public MessageHandler,
+ public Net::ElementalHandler
+{
+ public:
+ ElementalHandler();
+
+ A_DELETE_COPY(ElementalHandler)
+
+ void handleMessage(Net::MessageIn &msg) override final;
+};
+
+} // namespace EAthena
+
+#endif // NET_EATHENA_ELEMENTALHANDLER_H
diff --git a/src/net/eathena/generalhandler.cpp b/src/net/eathena/generalhandler.cpp
index 04755c478..c5730556a 100644
--- a/src/net/eathena/generalhandler.cpp
+++ b/src/net/eathena/generalhandler.cpp
@@ -47,6 +47,7 @@
#include "net/eathena/cashshophandler.h"
#include "net/eathena/chathandler.h"
#include "net/eathena/charserverhandler.h"
+#include "net/eathena/elementalhandler.h"
#include "net/eathena/familyhandler.h"
#include "net/eathena/friendshandler.h"
#include "net/eathena/gamehandler.h"
@@ -111,7 +112,8 @@ GeneralHandler::GeneralHandler() :
mMercenaryHandler(new MercenaryHandler),
mBuyingStoreHandler(new BuyingStoreHandler),
mHomunculusHandler(new HomunculusHandler),
- mFriendsHandler(new FriendsHandler)
+ mFriendsHandler(new FriendsHandler),
+ mElementalHandler(new ElementalHandler)
{
static const uint16_t _messages[] =
{
@@ -285,6 +287,7 @@ void GeneralHandler::load()
mNetwork->registerHandler(mBuyingStoreHandler);
mNetwork->registerHandler(mHomunculusHandler);
mNetwork->registerHandler(mFriendsHandler);
+ mNetwork->registerHandler(mElementalHandler);
}
void GeneralHandler::reload()
diff --git a/src/net/eathena/generalhandler.h b/src/net/eathena/generalhandler.h
index 5ab20c616..154c48d46 100644
--- a/src/net/eathena/generalhandler.h
+++ b/src/net/eathena/generalhandler.h
@@ -90,6 +90,7 @@ class GeneralHandler final : public MessageHandler,
MessageHandlerPtr mBuyingStoreHandler;
MessageHandlerPtr mHomunculusHandler;
MessageHandlerPtr mFriendsHandler;
+ MessageHandlerPtr mElementalHandler;
};
} // namespace EAthena
diff --git a/src/net/elementalhandler.h b/src/net/elementalhandler.h
new file mode 100644
index 000000000..e78825dfe
--- /dev/null
+++ b/src/net/elementalhandler.h
@@ -0,0 +1,42 @@
+/*
+ * The ManaPlus Client
+ * Copyright (C) 2011-2014 The ManaPlus Developers
+ *
+ * This file is part of The ManaPlus Client.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#ifndef NET_ELEMENTALHANDLER_H
+#define NET_ELEMENTALHANDLER_H
+
+#include <string>
+
+#include "localconsts.h"
+
+namespace Net
+{
+
+class ElementalHandler notfinal
+{
+ public:
+ virtual ~ElementalHandler()
+ { }
+};
+
+} // namespace Net
+
+extern Net::ElementalHandler *elementalHandler;
+
+#endif // NET_ELEMENTALHANDLER_H
diff --git a/src/net/net.cpp b/src/net/net.cpp
index ad6d16cd5..9822b0f03 100644
--- a/src/net/net.cpp
+++ b/src/net/net.cpp
@@ -49,6 +49,7 @@ namespace Net
class CashShopHandler;
class CharServerHandler;
class ChatHandler;
+ class ElementalHandler;
class FamilyHandler;
class FriendsHandler;
class GameHandler;
@@ -95,6 +96,7 @@ Net::QuestHandler *questHandler = nullptr;
Net::BuyingStoreHandler *buyingStoreHandler = nullptr;
Net::HomunculusHandler *homunculusHandler = nullptr;
Net::FriendsHandler *friendsHandler = nullptr;
+Net::ElementalHandler *elementalHandler = nullptr;
namespace Net
{
diff --git a/src/net/tmwa/elementalhandler.cpp b/src/net/tmwa/elementalhandler.cpp
new file mode 100644
index 000000000..f74f85a40
--- /dev/null
+++ b/src/net/tmwa/elementalhandler.cpp
@@ -0,0 +1,50 @@
+/*
+ * The ManaPlus Client
+ * Copyright (C) 2011-2014 The ManaPlus Developers
+ *
+ * This file is part of The ManaPlus Client.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include "net/tmwa/elementalhandler.h"
+
+#include "debug.h"
+
+extern Net::ElementalHandler *elementalHandler;
+
+namespace TmwAthena
+{
+
+ElementalHandler::ElementalHandler() :
+ MessageHandler()
+{
+ static const uint16_t _messages[] =
+ {
+ 0
+ };
+ handledMessages = _messages;
+ elementalHandler = this;
+}
+
+void ElementalHandler::handleMessage(Net::MessageIn &msg)
+{
+ switch (msg.getId())
+ {
+ default:
+ break;
+ }
+}
+
+} // namespace TmwAthena
diff --git a/src/net/tmwa/elementalhandler.h b/src/net/tmwa/elementalhandler.h
new file mode 100644
index 000000000..67409d30c
--- /dev/null
+++ b/src/net/tmwa/elementalhandler.h
@@ -0,0 +1,43 @@
+/*
+ * The ManaPlus Client
+ * Copyright (C) 2011-2014 The ManaPlus Developers
+ *
+ * This file is part of The ManaPlus Client.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#ifndef NET_TMWA_ELEMENTALHANDLER_H
+#define NET_TMWA_ELEMENTALHANDLER_H
+
+#include "net/elementalhandler.h"
+
+#include "net/tmwa/messagehandler.h"
+
+namespace TmwAthena
+{
+class ElementalHandler final : public MessageHandler,
+ public Net::ElementalHandler
+{
+ public:
+ ElementalHandler();
+
+ A_DELETE_COPY(ElementalHandler)
+
+ void handleMessage(Net::MessageIn &msg) override final;
+};
+
+} // namespace TmwAthena
+
+#endif // NET_TMWA_ELEMENTALHANDLER_H
diff --git a/src/net/tmwa/generalhandler.cpp b/src/net/tmwa/generalhandler.cpp
index 9fcdeed15..3129406ba 100644
--- a/src/net/tmwa/generalhandler.cpp
+++ b/src/net/tmwa/generalhandler.cpp
@@ -47,6 +47,7 @@
#include "net/tmwa/cashshophandler.h"
#include "net/tmwa/chathandler.h"
#include "net/tmwa/charserverhandler.h"
+#include "net/tmwa/elementalhandler.h"
#include "net/tmwa/familyhandler.h"
#include "net/tmwa/friendshandler.h"
#include "net/tmwa/gamehandler.h"
@@ -111,7 +112,8 @@ GeneralHandler::GeneralHandler() :
mMercenaryHandler(new MercenaryHandler),
mBuyingStoreHandler(new BuyingStoreHandler),
mHomunculusHandler(new HomunculusHandler),
- mFriendsHandler(new FriendsHandler)
+ mFriendsHandler(new FriendsHandler),
+ mElementalHandler(new ElementalHandler)
{
static const uint16_t _messages[] =
{
@@ -234,6 +236,7 @@ void GeneralHandler::load()
mNetwork->registerHandler(mBuyingStoreHandler);
mNetwork->registerHandler(mHomunculusHandler);
mNetwork->registerHandler(mFriendsHandler);
+ mNetwork->registerHandler(mElementalHandler);
}
void GeneralHandler::reload()
diff --git a/src/net/tmwa/generalhandler.h b/src/net/tmwa/generalhandler.h
index 179241a7c..bf13366c4 100644
--- a/src/net/tmwa/generalhandler.h
+++ b/src/net/tmwa/generalhandler.h
@@ -88,6 +88,7 @@ class GeneralHandler final : public MessageHandler,
MessageHandlerPtr mBuyingStoreHandler;
MessageHandlerPtr mHomunculusHandler;
MessageHandlerPtr mFriendsHandler;
+ MessageHandlerPtr mElementalHandler;
};
} // namespace TmwAthena