Skip to content

Commit

Permalink
MenuCharacter: Simpler tooltip text for primary stat bonuses
Browse files Browse the repository at this point in the history
  • Loading branch information
dorkster committed Jan 3, 2025
1 parent 795e53c commit 973418f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
12 changes: 10 additions & 2 deletions src/MenuCharacter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -476,8 +476,16 @@ void MenuCharacter::refreshStats() {

for (size_t j = 2; j < cstat.size(); ++j) {
cstat[j].tip.clear();
cstat[j].tip.addText(cstat[j].label->getText());
cstat[j].tip.addText(msg->getv("base (%d), bonus (%d)", *(base_stats[j-2]), *(base_stats_add[j-2])));
ss.str("");
ss << cstat[j].label->getText() << " (" << *(base_stats[j-2]);
if (*(base_stats_add[j-2]) > 0) {
ss << "+";
}
if (*(base_stats_add[j-2]) != 0) {
ss << *(base_stats_add[j-2]);
}
ss << ")";
cstat[j].tip.addText(ss.str());

bool have_bonus = false;
size_t elements_offset = Stats::COUNT + eset->damage_types.count;
Expand Down
2 changes: 1 addition & 1 deletion src/Version.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ FLARE. If not, see http://www.gnu.org/licenses/

#include <SDL.h>

Version VersionInfo::ENGINE(1, 14, 82);
Version VersionInfo::ENGINE(1, 14, 83);
Version VersionInfo::MIN(0, 0, 0);
Version VersionInfo::MAX(USHRT_MAX, USHRT_MAX, USHRT_MAX);

Expand Down

0 comments on commit 973418f

Please sign in to comment.