diff options
Diffstat (limited to 'crawl-ref/source/hiscores.cc')
-rw-r--r-- | crawl-ref/source/hiscores.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/crawl-ref/source/hiscores.cc b/crawl-ref/source/hiscores.cc index e77e56ec88..2a3c6b1902 100644 --- a/crawl-ref/source/hiscores.cc +++ b/crawl-ref/source/hiscores.cc @@ -32,6 +32,7 @@ #include <stdio.h> #include <ctype.h> #include <unistd.h> +#include <algorithm> #include <memory> #include "AppHdr.h" @@ -965,9 +966,9 @@ void scorefile_entry::init() final_hp = you.hp; final_max_hp = you.hp_max; final_max_max_hp = you.hp_max + player_rotted(); - str = you.strength; - intel = you.intel; - dex = you.dex; + str = std::max(you.strength - stat_modifier(STAT_STRENGTH), 1); + intel = std::max(you.intel - stat_modifier(STAT_INTELLIGENCE), 1); + dex = std::max(you.dex - stat_modifier(STAT_DEXTERITY), 1); god = you.religion; if (you.religion != GOD_NO_GOD) |