summaryrefslogtreecommitdiff
path: root/src/net/eathena
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-09-08 00:17:45 +0300
committerAndrei Karas <akaras@inbox.ru>2012-09-08 00:17:45 +0300
commit593cccb16074fe9269dd2f278bd79859769eb1fd (patch)
treed8b3d93001021c59622ea88140dbbef8aee05013 /src/net/eathena
parentb7e35a7bbd41c39fa675e77b2af6a11bb4d86dd2 (diff)
downloadplus-593cccb16074fe9269dd2f278bd79859769eb1fd.tar.gz
plus-593cccb16074fe9269dd2f278bd79859769eb1fd.tar.bz2
plus-593cccb16074fe9269dd2f278bd79859769eb1fd.tar.xz
plus-593cccb16074fe9269dd2f278bd79859769eb1fd.zip
Improve constructors in some classes.
Diffstat (limited to 'src/net/eathena')
-rw-r--r--src/net/eathena/adminhandler.cpp3
-rw-r--r--src/net/eathena/beinghandler.cpp1
-rw-r--r--src/net/eathena/buysellhandler.cpp4
-rw-r--r--src/net/eathena/charserverhandler.cpp4
-rw-r--r--src/net/eathena/chathandler.cpp4
-rw-r--r--src/net/eathena/gamehandler.cpp4
-rw-r--r--src/net/eathena/generalhandler.cpp3
-rw-r--r--src/net/eathena/guildhandler.cpp4
-rw-r--r--src/net/eathena/inventoryhandler.cpp4
-rw-r--r--src/net/eathena/itemhandler.cpp4
-rw-r--r--src/net/eathena/loginhandler.cpp4
-rw-r--r--src/net/eathena/messageout.cpp4
-rw-r--r--src/net/eathena/network.cpp3
-rw-r--r--src/net/eathena/npchandler.cpp4
-rw-r--r--src/net/eathena/partyhandler.cpp1
-rw-r--r--src/net/eathena/playerhandler.cpp4
-rw-r--r--src/net/eathena/specialhandler.cpp4
-rw-r--r--src/net/eathena/tradehandler.cpp4
18 files changed, 46 insertions, 17 deletions
diff --git a/src/net/eathena/adminhandler.cpp b/src/net/eathena/adminhandler.cpp
index 56b636b3b..0f9d373df 100644
--- a/src/net/eathena/adminhandler.cpp
+++ b/src/net/eathena/adminhandler.cpp
@@ -42,7 +42,8 @@ extern Net::AdminHandler *adminHandler;
namespace EAthena
{
-AdminHandler::AdminHandler()
+AdminHandler::AdminHandler() :
+ MessageHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/beinghandler.cpp b/src/net/eathena/beinghandler.cpp
index eb2ce5f74..857a0a8fb 100644
--- a/src/net/eathena/beinghandler.cpp
+++ b/src/net/eathena/beinghandler.cpp
@@ -58,6 +58,7 @@ namespace EAthena
{
BeingHandler::BeingHandler(bool enableSync):
+ MessageHandler(),
Ea::BeingHandler(enableSync)
{
static const uint16_t _messages[] =
diff --git a/src/net/eathena/buysellhandler.cpp b/src/net/eathena/buysellhandler.cpp
index 4dbc90e4b..3294bc1c8 100644
--- a/src/net/eathena/buysellhandler.cpp
+++ b/src/net/eathena/buysellhandler.cpp
@@ -52,7 +52,9 @@ extern Net::BuySellHandler *buySellHandler;
namespace EAthena
{
-BuySellHandler::BuySellHandler()
+BuySellHandler::BuySellHandler() :
+ MessageHandler(),
+ Ea::BuySellHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/charserverhandler.cpp b/src/net/eathena/charserverhandler.cpp
index 69ccc59a4..fcec75364 100644
--- a/src/net/eathena/charserverhandler.cpp
+++ b/src/net/eathena/charserverhandler.cpp
@@ -50,7 +50,9 @@ namespace EAthena
extern ServerInfo charServer;
extern ServerInfo mapServer;
-CharServerHandler::CharServerHandler()
+CharServerHandler::CharServerHandler() :
+ MessageHandler(),
+ Ea::CharServerHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/chathandler.cpp b/src/net/eathena/chathandler.cpp
index 77cf50acd..bd516ef26 100644
--- a/src/net/eathena/chathandler.cpp
+++ b/src/net/eathena/chathandler.cpp
@@ -45,7 +45,9 @@ extern Net::ChatHandler *chatHandler;
namespace EAthena
{
-ChatHandler::ChatHandler()
+ChatHandler::ChatHandler() :
+ MessageHandler(),
+ Ea::ChatHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/gamehandler.cpp b/src/net/eathena/gamehandler.cpp
index 09e6e4121..2ea687a88 100644
--- a/src/net/eathena/gamehandler.cpp
+++ b/src/net/eathena/gamehandler.cpp
@@ -39,7 +39,9 @@ namespace EAthena
extern ServerInfo mapServer;
-GameHandler::GameHandler()
+GameHandler::GameHandler() :
+ MessageHandler(),
+ Ea::GameHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/generalhandler.cpp b/src/net/eathena/generalhandler.cpp
index 82c52e943..b95991f55 100644
--- a/src/net/eathena/generalhandler.cpp
+++ b/src/net/eathena/generalhandler.cpp
@@ -72,7 +72,8 @@ namespace EAthena
ServerInfo charServer;
ServerInfo mapServer;
-GeneralHandler::GeneralHandler():
+GeneralHandler::GeneralHandler() :
+ MessageHandler(),
mAdminHandler(new AdminHandler),
mBeingHandler(new BeingHandler(config.getBoolValue("EnableSync"))),
mBuySellHandler(new BuySellHandler),
diff --git a/src/net/eathena/guildhandler.cpp b/src/net/eathena/guildhandler.cpp
index 4e22fe691..74a14f132 100644
--- a/src/net/eathena/guildhandler.cpp
+++ b/src/net/eathena/guildhandler.cpp
@@ -35,7 +35,9 @@ extern Net::GuildHandler *guildHandler;
namespace EAthena
{
-GuildHandler::GuildHandler()
+GuildHandler::GuildHandler() :
+ Ea::GuildHandler(),
+ MessageHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/inventoryhandler.cpp b/src/net/eathena/inventoryhandler.cpp
index 9f4b18ab2..e655920c1 100644
--- a/src/net/eathena/inventoryhandler.cpp
+++ b/src/net/eathena/inventoryhandler.cpp
@@ -33,7 +33,9 @@ extern Net::InventoryHandler *inventoryHandler;
namespace EAthena
{
-InventoryHandler::InventoryHandler()
+InventoryHandler::InventoryHandler() :
+ MessageHandler(),
+ Ea::InventoryHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/itemhandler.cpp b/src/net/eathena/itemhandler.cpp
index 8eedb8562..1aad83027 100644
--- a/src/net/eathena/itemhandler.cpp
+++ b/src/net/eathena/itemhandler.cpp
@@ -29,7 +29,9 @@
namespace EAthena
{
-ItemHandler::ItemHandler()
+ItemHandler::ItemHandler() :
+ MessageHandler(),
+ Ea::ItemHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/loginhandler.cpp b/src/net/eathena/loginhandler.cpp
index 1aeef1c09..21da4ba9f 100644
--- a/src/net/eathena/loginhandler.cpp
+++ b/src/net/eathena/loginhandler.cpp
@@ -41,7 +41,9 @@ namespace EAthena
extern ServerInfo charServer;
-LoginHandler::LoginHandler()
+LoginHandler::LoginHandler() :
+ MessageHandler(),
+ Ea::LoginHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/messageout.cpp b/src/net/eathena/messageout.cpp
index 6e35c50c4..bef5ff817 100644
--- a/src/net/eathena/messageout.cpp
+++ b/src/net/eathena/messageout.cpp
@@ -40,9 +40,9 @@ namespace EAthena
{
MessageOut::MessageOut(short id):
- Net::MessageOut(id)
+ Net::MessageOut(id),
+ mNetwork(EAthena::Network::instance())
{
- mNetwork = EAthena::Network::instance();
mNetwork->fixSendBuffer();
mData = mNetwork->mOutBuffer + mNetwork->mOutSize;
diff --git a/src/net/eathena/network.cpp b/src/net/eathena/network.cpp
index 475aaa72e..8a9a010f8 100644
--- a/src/net/eathena/network.cpp
+++ b/src/net/eathena/network.cpp
@@ -110,7 +110,8 @@ short packet_lengths[] =
Network *Network::mInstance = nullptr;
-Network::Network()
+Network::Network() :
+ Ea::Network()
{
mInstance = this;
}
diff --git a/src/net/eathena/npchandler.cpp b/src/net/eathena/npchandler.cpp
index aa77a23e5..4eaa00191 100644
--- a/src/net/eathena/npchandler.cpp
+++ b/src/net/eathena/npchandler.cpp
@@ -40,7 +40,9 @@ extern Net::NpcHandler *npcHandler;
namespace EAthena
{
-NpcHandler::NpcHandler()
+NpcHandler::NpcHandler() :
+ MessageHandler(),
+ Ea::NpcHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/partyhandler.cpp b/src/net/eathena/partyhandler.cpp
index e1052d50d..c452d2ae0 100644
--- a/src/net/eathena/partyhandler.cpp
+++ b/src/net/eathena/partyhandler.cpp
@@ -38,6 +38,7 @@ namespace EAthena
{
PartyHandler::PartyHandler() :
+ MessageHandler(),
Ea::PartyHandler()
{
static const uint16_t _messages[] =
diff --git a/src/net/eathena/playerhandler.cpp b/src/net/eathena/playerhandler.cpp
index 633bb12e4..0d4a51bc9 100644
--- a/src/net/eathena/playerhandler.cpp
+++ b/src/net/eathena/playerhandler.cpp
@@ -38,7 +38,9 @@ extern Net::PlayerHandler *playerHandler;
namespace EAthena
{
-PlayerHandler::PlayerHandler()
+PlayerHandler::PlayerHandler() :
+ MessageHandler(),
+ Ea::PlayerHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/specialhandler.cpp b/src/net/eathena/specialhandler.cpp
index 77bb5a1d2..668a67519 100644
--- a/src/net/eathena/specialhandler.cpp
+++ b/src/net/eathena/specialhandler.cpp
@@ -33,7 +33,9 @@ extern Net::SpecialHandler *specialHandler;
namespace EAthena
{
-SpecialHandler::SpecialHandler()
+SpecialHandler::SpecialHandler() :
+ MessageHandler(),
+ Ea::SpecialHandler()
{
static const uint16_t _messages[] =
{
diff --git a/src/net/eathena/tradehandler.cpp b/src/net/eathena/tradehandler.cpp
index a9416f8cd..cf33aa3cd 100644
--- a/src/net/eathena/tradehandler.cpp
+++ b/src/net/eathena/tradehandler.cpp
@@ -36,7 +36,9 @@ extern Net::TradeHandler *tradeHandler;
namespace EAthena
{
-TradeHandler::TradeHandler()
+TradeHandler::TradeHandler() :
+ MessageHandler(),
+ Ea::TradeHandler()
{
static const uint16_t _messages[] =
{