diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2005-04-07 16:17:00 +0000 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2005-04-07 16:17:00 +0000 |
commit | c96bbebb4b225e1e76297a93cd85f91ac4e92273 (patch) | |
tree | 939488b5924cdd0ed2296af64fdda637ebd0abf4 /src/gui/stats.cpp | |
parent | 660d3a52aa1bdcbac012a99db8f78642085b6cc8 (diff) | |
download | mana-client-c96bbebb4b225e1e76297a93cd85f91ac4e92273.tar.gz mana-client-c96bbebb4b225e1e76297a93cd85f91ac4e92273.tar.bz2 mana-client-c96bbebb4b225e1e76297a93cd85f91ac4e92273.tar.xz mana-client-c96bbebb4b225e1e76297a93cd85f91ac4e92273.zip |
Changed version from 0.0.11a to 0.0.11.1. Also made "+" buttons on stats window
and "Up" button on skills window disable when appropriate.
Diffstat (limited to 'src/gui/stats.cpp')
-rw-r--r-- | src/gui/stats.cpp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/gui/stats.cpp b/src/gui/stats.cpp index 655e217a..9b134876 100644 --- a/src/gui/stats.cpp +++ b/src/gui/stats.cpp @@ -94,7 +94,9 @@ void StatsWindow::update(){ statsStr[5] << "Luck:"; figureStr[5] << (int)char_info->LUK; - remainingStatsPointsStr << "Remaining Status Points : " << char_info->statsPointsToAttribute; + int statusPoints = char_info->statsPointsToAttribute; + + remainingStatsPointsStr << "Remaining Status Points: " << statusPoints; pointsStr[0] << (int)char_info->STRUp; pointsStr[1] << (int)char_info->AGIUp; @@ -103,6 +105,14 @@ void StatsWindow::update(){ pointsStr[4] << (int)char_info->DEXUp; pointsStr[5] << (int)char_info->LUKUp; + // Enable buttons for which there are enough status points + statsButton[0]->setEnabled(char_info->STRUp <= statusPoints); + statsButton[1]->setEnabled(char_info->AGIUp <= statusPoints); + statsButton[2]->setEnabled(char_info->VITUp <= statusPoints); + statsButton[3]->setEnabled(char_info->INTUp <= statusPoints); + statsButton[4]->setEnabled(char_info->DEXUp <= statusPoints); + statsButton[5]->setEnabled(char_info->LUKUp <= statusPoints); + // Update labels for (i = 0; i < 6; i++) { statsLabel[i]->setCaption(statsStr[i].str()); |