diff options
author | Chris Campbell <chriscampbell89@gmail.com> | 2014-05-21 19:02:26 +0100 |
---|---|---|
committer | Chris Campbell <chriscampbell89@gmail.com> | 2014-05-21 23:28:22 +0100 |
commit | 8cfef17bd41f1dd479a113daefb78197f96f8623 (patch) | |
tree | 4d44b47d3bea22a13e037856cc1a9ba5a803d1d7 /crawl-ref/source/mutation.cc | |
parent | e6cc52ce78a6bd57ad6659bf073e19e20d2bf90f (diff) | |
download | crawl-ref-8cfef17bd41f1dd479a113daefb78197f96f8623.tar.gz crawl-ref-8cfef17bd41f1dd479a113daefb78197f96f8623.zip |
Don't suppress non-physical mutations for thirsty vampires
Since they can now be mutated normally at all levels, also remove the
distinction between physical and non-physical mutations. This was
particularly complicated (specific mutations being suppressed by varying
degrees depending on hunger level).
Diffstat (limited to 'crawl-ref/source/mutation.cc')
-rw-r--r-- | crawl-ref/source/mutation.cc | 57 |
1 files changed, 9 insertions, 48 deletions
diff --git a/crawl-ref/source/mutation.cc b/crawl-ref/source/mutation.cc index 13ef821a36..08921f0e37 100644 --- a/crawl-ref/source/mutation.cc +++ b/crawl-ref/source/mutation.cc @@ -183,9 +183,7 @@ mutation_activity_type mutation_activity_level(mutation_type mut) if (you.form == TRAN_STATUE) { // Statues get all but the AC benefit from scales, but are not affected - // by other changes in body material or speed. We assume here that - // scale mutations are physical and therefore do not need the vampire - // checks below. + // by other changes in body material or speed. switch (mut) { case MUT_GELATINOUS_BODY: @@ -210,29 +208,7 @@ mutation_activity_type mutation_activity_level(mutation_type mut) } } - // Vampires may find their mutations suppressed by thirst. - if (you.is_undead == US_SEMI_UNDEAD) - { - // Innate mutations are always active - if (you.innate_mutation[mut]) - return MUTACT_FULL; - - // ... as are all mutations for semi-undead who are fully alive - if (you.hunger_state == HS_ENGORGED) - return MUTACT_FULL; - - // ... as are physical mutations. - if (get_mutation_def(mut).physical) - return MUTACT_FULL; - - // Other mutations are partially active at satiated and above. - if (you.hunger_state >= HS_SATIATED) - return MUTACT_HUNGER; - else - return MUTACT_INACTIVE; - } - else - return MUTACT_FULL; + return MUTACT_FULL; } // Counts of various statuses/types of mutations from the current/most @@ -240,7 +216,6 @@ mutation_activity_type mutation_activity_level(mutation_type mut) static int _num_full_suppressed = 0; static int _num_part_suppressed = 0; static int _num_form_based = 0; -static int _num_hunger_based = 0; static int _num_transient = 0; // Can the player transform? Returns true if the player is ever capable @@ -309,7 +284,7 @@ string describe_mutations(bool center_title) string scale_type = "plain brown"; _num_full_suppressed = _num_part_suppressed = 0; - _num_form_based = _num_hunger_based = 0; + _num_form_based = 0; _num_transient = 0; if (center_title) @@ -742,7 +717,7 @@ static void _display_vampire_attributes() string result; - const int lines = 13; + const int lines = 12; string column[lines][7] = { {" ", "<lightgreen>Alive</lightgreen> ", "<green>Full</green> ", @@ -768,14 +743,11 @@ static void _display_vampire_attributes() {"Torment resistance ", " ", " ", " ", " ", " ", " + "}, - {"\n<w>Other effects</w>\n" - "Non-physical \n" - "mutation effects ", "full ", "capped ", "capped ", "none ", "none ", "none "}, - - {"Bat Form ", "no ", "no ", "yes ", "yes ", "yes ", "yes "}, + {"\n<w>Transformations</w>\n" + "Bat form ", "no ", "no ", "yes ", "yes ", "yes ", "yes "}, - {"Other transformation \n" - "or going berserk ", "yes ", "yes ", "no ", "no ", "no ", "no "} + {"Other forms and \n" + "berserk ", "yes ", "yes ", "no ", "no ", "no ", "no "} }; int current = 0; @@ -922,8 +894,6 @@ void display_mutations() extra += "<darkgrey>(())</darkgrey>: Completely suppressed.\n"; if (_num_form_based) // TODO: check for form spells? extra += "<yellow>*</yellow> : Suppressed by some changes of form.\n"; - if (_num_hunger_based) - extra += "<lightred>+</lightred> : Suppressed by thirst.\n"; if (_num_transient) extra += "<magenta>[]</magenta> : Transient mutations."; if (you.species == SP_VAMPIRE) @@ -2053,9 +2023,7 @@ string mutation_desc(mutation_type mut, int level, bool colour) const bool ignore_player = (level != -1); const mutation_activity_type active = mutation_activity_level(mut); - const bool lowered = you.mutation[mut] > player_mutation_level(mut); - const bool partially_active = (active == MUTACT_PARTIAL - || active == MUTACT_HUNGER && lowered); + const bool partially_active = (active == MUTACT_PARTIAL); const bool fully_inactive = (active == MUTACT_INACTIVE); const bool temporary = (you.temp_mutation[mut] > 0); @@ -2109,13 +2077,6 @@ string mutation_desc(mutation_type mut, int level, bool colour) ++_num_form_based; result += colour ? "<yellow>*</yellow>" : "*"; } - - if (you.species == SP_VAMPIRE && !mdef.physical - && !you.innate_mutation[mut]) - { - ++_num_hunger_based; - result += colour ? "<lightred>+</lightred>" : "+"; - } } if (temporary) |