diff options
author | DracoOmega <draco_omega@live.com> | 2014-03-01 11:17:10 -0330 |
---|---|---|
committer | Steve Melenchuk <smelenchuk@gmail.com> | 2014-03-06 09:58:17 -0700 |
commit | 8651cb8188b23b451de89a85550bb7ac8d34770c (patch) | |
tree | 6bcbe62e18b643307ac335aa30ca4a68bd9e1aa1 /crawl-ref/source/l_you.cc | |
parent | a396766fc4ca89915ee2a08f8ba137ba81d1c33b (diff) | |
download | crawl-ref-8651cb8188b23b451de89a85550bb7ac8d34770c.tar.gz crawl-ref-8651cb8188b23b451de89a85550bb7ac8d34770c.zip |
Change how runrest_ignore_poison works for new poison
Since the full amount of poison can be known in advance, instead of
interrupting based on damage-per-tick and current absolute hp, use
the ratio of poisoning to current and max hp.
The option is now specified as cur_hp_ratio:max_hp_ratio in percent
(ignoring unless the poison is more than cur_hp_ratio of your current
hp and max_hp_ratio of your maximum hp).
I changed the default setting to 50:100, which is fairly arbitrary,
and still likely interrupts on many situations that you'd rather
rest off the poison without interruption (after all, even 90%
poisoning is pretty safe if in a known-safe location). Plus, low hp
warnings will still constantly interrupt if you fall below the
threshold for them, which is also really bad.
Basically, this still needs a lot of work before the idealized
non-obtrusive resting that is one of the main points of deterministic
poison actually functions, but this is at least an improvement over
the current settings, I think.
Diffstat (limited to 'crawl-ref/source/l_you.cc')
-rw-r--r-- | crawl-ref/source/l_you.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/crawl-ref/source/l_you.cc b/crawl-ref/source/l_you.cc index 37fff9c199..9d21d3e8c2 100644 --- a/crawl-ref/source/l_you.cc +++ b/crawl-ref/source/l_you.cc @@ -95,6 +95,7 @@ LUARET1(you_god_likes_fresh_corpses, boolean, god_likes_fresh_corpses(you.religion)) LUARET2(you_hp, number, you.hp, you.hp_max) LUARET2(you_mp, number, you.magic_points, you.max_magic_points) +LUARET1(you_poisoning, number, get_player_poisoning()) LUARET1(you_hunger, number, you.hunger_state) LUARET1(you_hunger_name, string, hunger_level()) LUARET2(you_strength, number, you.strength(false), you.max_strength()) @@ -485,6 +486,7 @@ static const struct luaL_reg you_clib[] = { "anchored", you_anchored }, { "rooted", you_rooted }, { "poisoned", you_poisoned }, + { "poisoning", you_poisoning }, { "invisible", you_invisible }, { "mesmerised", you_mesmerised }, { "on_fire", you_on_fire }, |