diff options
author | Andrei Karas <akaras@inbox.ru> | 2017-07-31 19:42:48 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2017-07-31 19:42:48 +0300 |
commit | 6a64f7e58501280751d6cbe4f3a474cdb1a93f46 (patch) | |
tree | 260514513a71fa12aef307c596fbe13be670f320 /src/being/being.cpp | |
parent | 97109e6260af3eab9c2fd7bae7dbcd0935f70da7 (diff) | |
download | mv-6a64f7e58501280751d6cbe4f3a474cdb1a93f46.tar.gz mv-6a64f7e58501280751d6cbe4f3a474cdb1a93f46.tar.bz2 mv-6a64f7e58501280751d6cbe4f3a474cdb1a93f46.tar.xz mv-6a64f7e58501280751d6cbe4f3a474cdb1a93f46.zip |
Improve a bit settings.playerNameOffset usage.
Diffstat (limited to 'src/being/being.cpp')
-rw-r--r-- | src/being/being.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/being/being.cpp b/src/being/being.cpp index c051d3038..bf1b2db59 100644 --- a/src/being/being.cpp +++ b/src/being/being.cpp @@ -2292,8 +2292,7 @@ void Being::drawEmotion(Graphics *restrict const graphics, } else { - int height = settings.playerNameOffset; - y = py + height + 16; + y = py + settings.playerNameOffset + 16; } } else @@ -2315,7 +2314,7 @@ void Being::drawEmotion(Graphics *restrict const graphics, else if (mShowBadges == BadgeDrawType::Bottom) { x = px + 8 - mBadgesCount * 8; - int height = settings.playerNameOffset; + const int height = settings.playerNameOffset; if (mVisibleNamePos == VisibleNamePos::Buttom) y = py + height; else @@ -2453,8 +2452,7 @@ void Being::updateCoords() restrict2 if (mType == ActorType::Monster || mVisibleNamePos == VisibleNamePos::Top) { - int height = settings.playerNameOffset; - offsetY += - height - mDispName->getHeight(); + offsetY += - settings.playerNameOffset - mDispName->getHeight(); } mDispName->adviseXY(offsetX, offsetY, mMoveNames); |