summaryrefslogtreecommitdiff
path: root/src/being/being.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-02-15 15:08:47 +0300
committerAndrei Karas <akaras@inbox.ru>2015-02-15 15:18:20 +0300
commit77a52b24c88dd113a74ff55cecb63a7214193fdf (patch)
tree218897c6979c994f9fb5d50ec976dc90075b8576 /src/being/being.cpp
parente59fc67ba665be08a9d9a3fa27139d31168d324a (diff)
downloadmanaverse-77a52b24c88dd113a74ff55cecb63a7214193fdf.tar.gz
manaverse-77a52b24c88dd113a74ff55cecb63a7214193fdf.tar.bz2
manaverse-77a52b24c88dd113a74ff55cecb63a7214193fdf.tar.xz
manaverse-77a52b24c88dd113a74ff55cecb63a7214193fdf.zip
Show buy or sell in player context menu based on enabled shop types.
Diffstat (limited to 'src/being/being.cpp')
-rw-r--r--src/being/being.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp
index 97fad3c59..4a3e4d0cb 100644
--- a/src/being/being.cpp
+++ b/src/being/being.cpp
@@ -3551,3 +3551,13 @@ void Being::enableShop(const bool b)
mShop = b;
updateName();
}
+
+bool Being::isBuyShopEnabled() const
+{
+ return mShop && (!serverFeatures->haveVending() || !mBuyBoard.empty());
+}
+
+bool Being::isSellShopEnabled() const
+{
+ return mShop && (!serverFeatures->haveVending() || !mSellBoard.empty());
+}