summaryrefslogtreecommitdiff
path: root/src/being/being.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-07-29 14:33:37 +0300
committerAndrei Karas <akaras@inbox.ru>2015-07-29 14:33:37 +0300
commitaae7a5ec7b6d962edd6620f1aedd468a6bc98e1a (patch)
tree4352a052e5254b0f16b56aab304dcb3ce107a59b /src/being/being.cpp
parentcd2a71bfc4d3339dd6cf18b5a311e57d58fb548c (diff)
downloadManaVerse-aae7a5ec7b6d962edd6620f1aedd468a6bc98e1a.tar.gz
ManaVerse-aae7a5ec7b6d962edd6620f1aedd468a6bc98e1a.tar.bz2
ManaVerse-aae7a5ec7b6d962edd6620f1aedd468a6bc98e1a.tar.xz
ManaVerse-aae7a5ec7b6d962edd6620f1aedd468a6bc98e1a.zip
Add ability to show badges under nick.
Add option for select how show badges.
Diffstat (limited to 'src/being/being.cpp')
-rw-r--r--src/being/being.cpp14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp
index 6cc8bae4b..f0cc40bd9 100644
--- a/src/being/being.cpp
+++ b/src/being/being.cpp
@@ -118,8 +118,7 @@ bool Being::mEnableReorderSprites = true;
bool Being::mHideErased = false;
Move Being::mMoveNames = Move_false;
bool Being::mUseDiagonal = true;
-bool Being::mShowBadges = true;
-bool Being::mShowBadgesTop = true;
+uint8_t Being::mShowBadges = 1;
int Being::mAwayEffect = -1;
std::list<BeingCacheEntry*> beingInfoCache;
@@ -1885,12 +1884,18 @@ void Being::drawEmotion(Graphics *const graphics,
{
int x;
int y;
- if (!mShowBadgesTop && mDispName && gui)
+ if (mShowBadges == 2 && mDispName && gui)
{
Font *const font = gui->getFont();
x = mDispName->getX() - offsetX + mDispName->getWidth();
y = mDispName->getY() - offsetY - font->getHeight();
}
+ else if (mShowBadges == 3 && mDispName && gui)
+ {
+ Font *const font = gui->getFont();
+ x = px + 8 - mBadgesCount * 8;
+ y = mDispName->getY() - offsetY;
+ }
else
{
x = px + 8 - mBadgesCount * 8;
@@ -2424,8 +2429,7 @@ void Being::reReadConfig()
mHideErased = config.getBoolValue("hideErased");
mMoveNames = fromBool(config.getBoolValue("moveNames"), Move);
mUseDiagonal = config.getBoolValue("useDiagonalSpeed");
- mShowBadges = config.getBoolValue("showBadges");
- mShowBadgesTop = config.getBoolValue("showBadgesTop");
+ mShowBadges = config.getIntValue("showBadges");
mUpdateConfigTime = cur_time;
}