summaryrefslogtreecommitdiffstats
path: root/crawl-ref
diff options
context:
space:
mode:
Diffstat (limited to 'crawl-ref')
-rw-r--r--crawl-ref/source/skills2.cc31
-rw-r--r--crawl-ref/source/transfor.cc4
2 files changed, 19 insertions, 16 deletions
diff --git a/crawl-ref/source/skills2.cc b/crawl-ref/source/skills2.cc
index 6cff23559f..79ea20dd57 100644
--- a/crawl-ref/source/skills2.cc
+++ b/crawl-ref/source/skills2.cc
@@ -2184,21 +2184,24 @@ int calc_hp(bool real_hp)
hitp /= 10;
}
- // some transformations give you extra hp
- switch (you.attribute[ATTR_TRANSFORMATION] && !real_hp)
+ if (!real_hp)
{
- case TRAN_STATUE:
- hitp *= 15;
- hitp /= 10;
- break;
- case TRAN_ICE_BEAST:
- hitp *= 12;
- hitp /= 10;
- break;
- case TRAN_DRAGON:
- hitp *= 16;
- hitp /= 10;
- break;
+ // some transformations give you extra hp
+ switch (you.attribute[ATTR_TRANSFORMATION])
+ {
+ case TRAN_STATUE:
+ hitp *= 15;
+ hitp /= 10;
+ break;
+ case TRAN_ICE_BEAST:
+ hitp *= 12;
+ hitp /= 10;
+ break;
+ case TRAN_DRAGON:
+ hitp *= 16;
+ hitp /= 10;
+ break;
+ }
}
// frail and robust mutations
diff --git a/crawl-ref/source/transfor.cc b/crawl-ref/source/transfor.cc
index f2a495fef1..8bcf271a64 100644
--- a/crawl-ref/source/transfor.cc
+++ b/crawl-ref/source/transfor.cc
@@ -584,8 +584,7 @@ void untransform(void)
if (you.species == SP_NAGA || you.species == SP_CENTAUR)
remove_one_equip(EQ_BOOTS);
- calc_hp();
- if (hp_downscale != 10)
+ if (hp_downscale != 10 && you.hp != you.hp_max)
{
you.hp = you.hp * 10 / hp_downscale;
if (you.hp < 1)
@@ -593,6 +592,7 @@ void untransform(void)
else if (you.hp > you.hp_max)
you.hp = you.hp_max;
}
+ calc_hp();
} // end untransform()
// XXX: This whole system is a mess as it still relies on special