summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/game.cpp6
-rw-r--r--src/localplayer.cpp5
-rw-r--r--src/net/ea/gui/partytab.cpp4
-rw-r--r--src/net/ea/gui/partytab.h4
-rw-r--r--src/net/ea/partyhandler.cpp3
5 files changed, 12 insertions, 10 deletions
diff --git a/src/game.cpp b/src/game.cpp
index 9ca58461..427f70b6 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -748,14 +748,10 @@ void Game::handleInput()
{
case KeyboardConfig::KEY_PICKUP:
{
-#ifdef MANASERV_SUPPORT
const Vector &pos = player_node->getPosition();
Uint16 x = (int) pos.x / 32;
Uint16 y = (int) pos.y / 32;
-#else
- Uint16 x = player_node->getTileX();
- Uint16 y = player_node->getTileY();
-#endif
+
FloorItem *item =
floorItemManager->findByCoordinates(x, y);
diff --git a/src/localplayer.cpp b/src/localplayer.cpp
index 6ec334ed..79ea00af 100644
--- a/src/localplayer.cpp
+++ b/src/localplayer.cpp
@@ -579,14 +579,11 @@ void LocalPlayer::startWalking(unsigned char dir)
if (!mMap || !dir)
return;
-#ifdef MANASERV_SUPPORT
- const Vector &pos = getPosition();
-#endif
-
if (mAction == WALK && !mPath.empty())
{
// Just finish the current action, otherwise we get out of sync
#ifdef MANASERV_SUPPORT
+ const Vector &pos = getPosition();
Being::setDestination(pos.x, pos.y);
#else
Being::setDestination(getTileX(), getTileY());
diff --git a/src/net/ea/gui/partytab.cpp b/src/net/ea/gui/partytab.cpp
index 24bd739b..d555743c 100644
--- a/src/net/ea/gui/partytab.cpp
+++ b/src/net/ea/gui/partytab.cpp
@@ -35,6 +35,8 @@
#include "utils/gettext.h"
#include "utils/stringutils.h"
+namespace EAthena {
+
PartyTab::PartyTab() :
ChatTab(_("Party"))
{
@@ -206,3 +208,5 @@ int PartyTab::getType() const
{
return ChatTab::PARTY;
}
+
+} // namespace EAthena
diff --git a/src/net/ea/gui/partytab.h b/src/net/ea/gui/partytab.h
index afbc8fd9..9ab0862a 100644
--- a/src/net/ea/gui/partytab.h
+++ b/src/net/ea/gui/partytab.h
@@ -24,6 +24,8 @@
#include "gui/widgets/chattab.h"
+namespace EAthena {
+
/**
* A tab for a party chat channel.
*/
@@ -45,4 +47,6 @@ class PartyTab : public ChatTab
extern PartyTab *partyTab;
+} // namespace EAthena
+
#endif // EA_PARTYTAB_H
diff --git a/src/net/ea/partyhandler.cpp b/src/net/ea/partyhandler.cpp
index bd69fa05..55331640 100644
--- a/src/net/ea/partyhandler.cpp
+++ b/src/net/ea/partyhandler.cpp
@@ -38,11 +38,12 @@
#include "utils/gettext.h"
#include "utils/stringutils.h"
-PartyTab *partyTab = 0;
extern Net::PartyHandler *partyHandler;
namespace EAthena {
+PartyTab *partyTab = 0;
+
PartyHandler::PartyHandler():
mShareExp(PARTY_SHARE_UNKNOWN), mShareItems(PARTY_SHARE_UNKNOWN)
{