diff options
author | Fate <fate-tmw@googlemail.com> | 2008-11-23 11:32:07 -0700 |
---|---|---|
committer | Fate <fate-tmw@googlemail.com> | 2008-11-23 11:32:07 -0700 |
commit | d011f8f984f454a76adaf04142df0daa03dd00a8 (patch) | |
tree | d03e1deb52c863e497aed2b02d3ec34f1069653a /src | |
parent | 12d50ac3bd08576ea23e00778463c3efa6b3a931 (diff) | |
download | mana-client-d011f8f984f454a76adaf04142df0daa03dd00a8.tar.gz mana-client-d011f8f984f454a76adaf04142df0daa03dd00a8.tar.bz2 mana-client-d011f8f984f454a76adaf04142df0daa03dd00a8.tar.xz mana-client-d011f8f984f454a76adaf04142df0daa03dd00a8.zip |
Grey out magic bar if matk negative, update F2 window magic bar
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/ministatus.cpp | 5 | ||||
-rw-r--r-- | src/gui/status.cpp | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/src/gui/ministatus.cpp b/src/gui/ministatus.cpp index 077e2331..388b5fbf 100644 --- a/src/gui/ministatus.cpp +++ b/src/gui/ministatus.cpp @@ -99,6 +99,11 @@ void MiniStatusWindow::update() mHpBar->setProgress((float) player_node->mHp / player_node->mMaxHp); mMpBar->setProgress((float) player_node->mMp / player_node->mMaxMp); + if (player_node->MATK <= 0) + mMpBar->setColor(100, 100, 100); // grey, to indicate that we lack magic + else + mMpBar->setColor(143, 192, 211); // blue, to indicate that we have magic + mXpBar->setProgress( (float) player_node->getXp() / player_node->mXpForNextLevel); diff --git a/src/gui/status.cpp b/src/gui/status.cpp index 927b3554..eebd0a21 100644 --- a/src/gui/status.cpp +++ b/src/gui/status.cpp @@ -265,7 +265,7 @@ void StatusWindow::update() } mHpBar->setProgress((float) mPlayer->mHp / (float) mPlayer->mMaxHp); - // mMpBar->setProgress((float)mPlayer->mp / (float)mPlayer->maxMp); + mMpBar->setProgress((float) mPlayer->mMp / (float) mPlayer->mMaxMp); mXpBar->setProgress( (float) mPlayer->getXp() / (float) mPlayer->mXpForNextLevel); |