summaryrefslogtreecommitdiff
path: root/src/gui/windows/shopwindow.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-05-11 19:28:57 +0300
committerAndrei Karas <akaras@inbox.ru>2014-05-11 19:28:57 +0300
commit87c59212f8590a8dd72fac3e320fcb2ada781355 (patch)
tree198d627c44f1164140659827a5c782d30bec375b /src/gui/windows/shopwindow.cpp
parent02e91411eb9961e95f856bd717d6ca0d8ec0e435 (diff)
downloadmv-87c59212f8590a8dd72fac3e320fcb2ada781355.tar.gz
mv-87c59212f8590a8dd72fac3e320fcb2ada781355.tar.bz2
mv-87c59212f8590a8dd72fac3e320fcb2ada781355.tar.xz
mv-87c59212f8590a8dd72fac3e320fcb2ada781355.zip
Move player attributes into separate file.
Diffstat (limited to 'src/gui/windows/shopwindow.cpp')
-rw-r--r--src/gui/windows/shopwindow.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/gui/windows/shopwindow.cpp b/src/gui/windows/shopwindow.cpp
index b44dcc19e..edd3efbc7 100644
--- a/src/gui/windows/shopwindow.cpp
+++ b/src/gui/windows/shopwindow.cpp
@@ -48,6 +48,7 @@
#include "soundconsts.h"
#include "soundmanager.h"
+#include "being/attributes.h"
#include "being/localplayer.h"
#include "being/playerinfo.h"
#include "being/playerrelations.h"
@@ -593,9 +594,9 @@ void ShopWindow::giveList(const std::string &nick, const int mode)
{
int amount = item->getQuantity();
if (item->getPrice() * amount > PlayerInfo::getAttribute(
- PlayerInfo::MONEY))
+ Attributes::MONEY))
{
- amount = PlayerInfo::getAttribute(PlayerInfo::MONEY)
+ amount = PlayerInfo::getAttribute(Attributes::MONEY)
/ item->getPrice();
}
@@ -655,9 +656,9 @@ void ShopWindow::showList(const std::string &nick, std::string data)
return;
if (buyDialog)
- buyDialog->setMoney(PlayerInfo::getAttribute(PlayerInfo::MONEY));
+ buyDialog->setMoney(PlayerInfo::getAttribute(Attributes::MONEY));
if (sellDialog)
- sellDialog->setMoney(PlayerInfo::getAttribute(PlayerInfo::MONEY));
+ sellDialog->setMoney(PlayerInfo::getAttribute(Attributes::MONEY));
for (unsigned f = 0; f < data.length(); f += 9)
{