summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDavid Athay <ko2fan@gmail.com>2009-05-18 17:19:43 +0100
committerDavid Athay <ko2fan@gmail.com>2009-05-18 17:19:43 +0100
commite7df8c9dd7ebc14c1263c19c6a238ebcf4fd9465 (patch)
tree542183b7d7490831f4f8289ce821c483581ead14 /src
parentaaec4d115cd0048bbc4bed3d8b1d33492b2a51fa (diff)
downloadmana-client-e7df8c9dd7ebc14c1263c19c6a238ebcf4fd9465.tar.gz
mana-client-e7df8c9dd7ebc14c1263c19c6a238ebcf4fd9465.tar.bz2
mana-client-e7df8c9dd7ebc14c1263c19c6a238ebcf4fd9465.tar.xz
mana-client-e7df8c9dd7ebc14c1263c19c6a238ebcf4fd9465.zip
Fixed compilation for tmwserv
Diffstat (limited to 'src')
-rw-r--r--src/gui/connection.cpp2
-rw-r--r--src/gui/connection.h6
-rw-r--r--src/gui/outfitwindow.cpp9
3 files changed, 12 insertions, 5 deletions
diff --git a/src/gui/connection.cpp b/src/gui/connection.cpp
index 0862ee69..4863edcd 100644
--- a/src/gui/connection.cpp
+++ b/src/gui/connection.cpp
@@ -30,7 +30,7 @@
#include "utils/gettext.h"
-ConnectionDialog::ConnectionDialog(int previousState):
+ConnectionDialog::ConnectionDialog(State previousState):
Window("Info"), mProgress(0), mPreviousState(previousState)
{
setContentSize(200, 100);
diff --git a/src/gui/connection.h b/src/gui/connection.h
index 62441fa9..d6059c3f 100644
--- a/src/gui/connection.h
+++ b/src/gui/connection.h
@@ -24,6 +24,8 @@
#include "gui/widgets/window.h"
+#include "main.h"
+
#include <guichan/actionlistener.hpp>
class ProgressBar;
@@ -41,7 +43,7 @@ class ConnectionDialog : public Window, gcn::ActionListener
*
* @see Window::Window
*/
- ConnectionDialog(int previousState);
+ ConnectionDialog(State previousState);
/**
* Called when the user presses Cancel. Restores the global state to
@@ -54,7 +56,7 @@ class ConnectionDialog : public Window, gcn::ActionListener
private:
ProgressBar *mProgressBar;
float mProgress;
- int mPreviousState;
+ State mPreviousState;
};
#endif
diff --git a/src/gui/outfitwindow.cpp b/src/gui/outfitwindow.cpp
index 53950299..f43e1440 100644
--- a/src/gui/outfitwindow.cpp
+++ b/src/gui/outfitwindow.cpp
@@ -153,9 +153,14 @@ void OutfitWindow::wearOutfit(int outfit)
//non vis is 3,4,7
if (i != 3 && i != 4 && i != 7)
{
- if (!(item = player_node->getInventory()->getItem(player_node
- ->mEquipment.get()->getEquipment(i))))
+#ifdef TMWSERV_SUPPORT
+ if (!(item = player_node->mEquipment.get()->getEquipment(i)))
continue;
+#else
+ if (!(item = player_node->getInventory()->getItem(
+ player_node->mEquipment.get()->getEquipment(i))))
+ continue;
+#endif
Net::getInventoryHandler()->unequipItem(item);
}
}