summaryrefslogtreecommitdiff
path: root/src/being
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-03-15 22:03:17 +0300
committerAndrei Karas <akaras@inbox.ru>2015-03-16 13:50:43 +0300
commit23034a47937c109590eb60e4ee0efa32a8c9e45e (patch)
tree844c716da20752dcbb0aead649011f54d8062635 /src/being
parent4638f969d4206ba8dd857eb6d2758106cc5268df (diff)
downloadmanaverse-23034a47937c109590eb60e4ee0efa32a8c9e45e.tar.gz
manaverse-23034a47937c109590eb60e4ee0efa32a8c9e45e.tar.bz2
manaverse-23034a47937c109590eb60e4ee0efa32a8c9e45e.tar.xz
manaverse-23034a47937c109590eb60e4ee0efa32a8c9e45e.zip
Remove useless includes from cpp files
Diffstat (limited to 'src/being')
-rw-r--r--src/being/actorsprite.cpp2
-rw-r--r--src/being/being.cpp1
-rw-r--r--src/being/localplayer.cpp7
-rw-r--r--src/being/playerinfo.cpp19
-rw-r--r--src/being/playerinfo.h2
-rw-r--r--src/being/playerrelations.cpp2
6 files changed, 10 insertions, 23 deletions
diff --git a/src/being/actorsprite.cpp b/src/being/actorsprite.cpp
index 9f21d4996..31e8ce7be 100644
--- a/src/being/actorsprite.cpp
+++ b/src/being/actorsprite.cpp
@@ -30,8 +30,6 @@
#include "gui/theme.h"
-#include "listeners/actorspritelistener.h"
-
#include "particle/particle.h"
#include "resources/resourcemanager.h"
diff --git a/src/being/being.cpp b/src/being/being.cpp
index 9e9316417..468e2b066 100644
--- a/src/being/being.cpp
+++ b/src/being/being.cpp
@@ -42,7 +42,6 @@
#include "enums/net/packettypes.h"
-#include "particle/particle.h"
#include "particle/particleinfo.h"
#include "gui/gui.h"
diff --git a/src/being/localplayer.cpp b/src/being/localplayer.cpp
index cd9b642f0..a588246a2 100644
--- a/src/being/localplayer.cpp
+++ b/src/being/localplayer.cpp
@@ -25,10 +25,8 @@
#include "actormanager.h"
#include "animatedsprite.h"
#include "configuration.h"
-#include "dropshortcut.h"
#include "gamemodifiers.h"
#include "guild.h"
-#include "item.h"
#include "party.h"
#include "settings.h"
#include "soundconsts.h"
@@ -38,7 +36,6 @@
#include "being/beingflag.h"
#include "being/crazymoves.h"
-#include "being/playerinfo.h"
#include "being/playerrelations.h"
#include "enums/being/attributes.h"
@@ -69,7 +66,6 @@
#include "net/chathandler.h"
#include "net/inventoryhandler.h"
#include "net/packetlimiter.h"
-#include "net/pethandler.h"
#include "net/playerhandler.h"
#include "net/serverfeatures.h"
@@ -77,7 +73,6 @@
#include "resources/itemslot.h"
#include "resources/mapitemtype.h"
-#include "resources/db/emotedb.h"
#include "resources/db/weaponsdb.h"
#include "resources/map/map.h"
@@ -94,8 +89,6 @@
#include "mumblemanager.h"
#endif
-#include <climits>
-
#include "debug.h"
static const int16_t awayLimitTimer = 60;
diff --git a/src/being/playerinfo.cpp b/src/being/playerinfo.cpp
index dc7eb3732..ff4efb79d 100644
--- a/src/being/playerinfo.cpp
+++ b/src/being/playerinfo.cpp
@@ -21,17 +21,16 @@
#include "being/playerinfo.h"
-#include "client.h"
#include "configuration.h"
-#include "inventory.h"
#include "itemsoundmanager.h"
-#include "being/homunculusinfo.h"
#include "being/localplayer.h"
+
+#ifdef EATHENA_SUPPORT
+#include "being/homunculusinfo.h"
#include "being/mercenaryinfo.h"
#include "being/petinfo.h"
-
-#include "enums/inventorytype.h"
+#endif
#include "enums/being/attributes.h"
@@ -46,8 +45,6 @@
#include "utils/delete2.h"
-#include "listeners/statlistener.h"
-
#include "debug.h"
namespace PlayerInfo
@@ -59,11 +56,11 @@ int mCharId = 0;
Inventory *mInventory = nullptr;
#ifdef EATHENA_SUPPORT
Inventory *mCartInventory = nullptr;
-#endif
-Equipment *mEquipment = nullptr;
MercenaryInfo *mMercenary = nullptr;
HomunculusInfo *mHomunculus = nullptr;
PetInfo *mPet = nullptr;
+#endif
+Equipment *mEquipment = nullptr;
int mPetBeingId = 0;
GuildPositionFlags::Type mGuildPositionFlags = GuildPositionFlags::None;
@@ -394,7 +391,9 @@ void init()
void deinit()
{
clearInventory();
+#ifdef EATHENA_SUPPORT
delete2(mMercenary);
+#endif
mPetBeingId = 0;
}
@@ -477,6 +476,7 @@ bool isItemProtected(const int id)
return mProtectedItems.find(id) != mProtectedItems.end();
}
+#ifdef EATHENA_SUPPORT
void setMercenary(MercenaryInfo *const info)
{
if (mMercenary)
@@ -559,7 +559,6 @@ int getMercenaryId()
return mMercenary ? mMercenary->id : 0;
}
-#ifdef EATHENA_SUPPORT
void updateMoveAI()
{
if (mMercenary)
diff --git a/src/being/playerinfo.h b/src/being/playerinfo.h
index 49f4d54e5..20da29e44 100644
--- a/src/being/playerinfo.h
+++ b/src/being/playerinfo.h
@@ -239,6 +239,7 @@ namespace PlayerInfo
bool isItemProtected(const int id);
+#ifdef EATHENA_SUPPORT
MercenaryInfo *getMercenary();
void setMercenary(MercenaryInfo *const info);
@@ -263,7 +264,6 @@ namespace PlayerInfo
int getMercenaryId();
-#ifdef EATHENA_SUPPORT
void updateMoveAI();
void updateAttackAi(const int targetId, const bool keep);
diff --git a/src/being/playerrelations.cpp b/src/being/playerrelations.cpp
index f0d635561..22f685044 100644
--- a/src/being/playerrelations.cpp
+++ b/src/being/playerrelations.cpp
@@ -33,8 +33,6 @@
#include "listeners/playerrelationslistener.h"
-#include <algorithm>
-
#include "debug.h"
typedef std::map<std::string, PlayerRelation *> PlayerRelations;