summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--crawl-ref/source/spl-cast.cc13
-rw-r--r--crawl-ref/source/spl-cast.h2
2 files changed, 10 insertions, 5 deletions
diff --git a/crawl-ref/source/spl-cast.cc b/crawl-ref/source/spl-cast.cc
index b2a24c538d..d32187743f 100644
--- a/crawl-ref/source/spl-cast.cc
+++ b/crawl-ref/source/spl-cast.cc
@@ -2296,16 +2296,21 @@ static unsigned int _breakpoint_rank(int val, const int breakpoints[],
return result;
}
-const char* spell_hunger_string( spell_type spell )
+const char* spell_hunger_string(spell_type spell)
{
if (you.is_undead == US_UNDEAD)
- return "N/A";
+ return ("N/A");
const int hunger = spell_hunger(spell);
+
+ // Spell hunger is "Fruit" if casting the spell five times costs at
+ // most one "Fruit".
const char* hunger_descriptions[] = {
- "None", "Grape", "Apple", "Choko", "Ration"
+ "None", "Sultana", "Strawberry", "Choko", "Honeycomb", "Ration"
};
- const int breakpoints[] = { 1, 25, 150, 500 };
+
+ const int breakpoints[] = { 1, 15, 41, 121, 401 };
+
return (hunger_descriptions[_breakpoint_rank(hunger, breakpoints,
ARRAYSZ(breakpoints))]);
}
diff --git a/crawl-ref/source/spl-cast.h b/crawl-ref/source/spl-cast.h
index a16a3d8b7a..51cf0865d4 100644
--- a/crawl-ref/source/spl-cast.h
+++ b/crawl-ref/source/spl-cast.h
@@ -84,6 +84,6 @@ int spell_power_bars(spell_type spell);
std::string spell_power_string(spell_type spell);
std::string spell_range_string(spell_type spell);
std::string spell_schools_string(spell_type spell);
-const char* spell_hunger_string( spell_type spell );
+const char* spell_hunger_string(spell_type spell);
#endif