summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/localplayer.cpp8
-rw-r--r--src/localplayer.h3
2 files changed, 9 insertions, 2 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp
index d20ebcc3..34ab5246 100644
--- a/src/localplayer.cpp
+++ b/src/localplayer.cpp
@@ -911,6 +911,14 @@ void LocalPlayer::setMaxMP(int value)
statusWindow->update(StatusWindow::MP);
}
+void LocalPlayer::setMoney(int value)
+{
+ mMoney = value;
+
+ if (statusWindow)
+ statusWindow->update(StatusWindow::MONEY);
+}
+
void LocalPlayer::pickedUp(const ItemInfo &itemInfo, int amount)
{
if (!amount)
diff --git a/src/localplayer.h b/src/localplayer.h
index 140d64b4..a3ed5f29 100644
--- a/src/localplayer.h
+++ b/src/localplayer.h
@@ -309,8 +309,7 @@ class LocalPlayer : public Player
int getMoney() const
{ return mMoney; }
- void setMoney(int value)
- { mMoney = value; }
+ void setMoney(int value);
int getTotalWeight() const
{ return mTotalWeight; }