diff options
author | Robert Vollmert <rvollmert@gmx.net> | 2010-04-14 14:48:04 +0200 |
---|---|---|
committer | Robert Vollmert <rvollmert@gmx.net> | 2010-04-14 15:19:36 +0200 |
commit | 59cb47231f09c696c38ef72956e962c5b9cea191 (patch) | |
tree | 191a1257360141749e8117b0649966e089e047a2 /crawl-ref/source/fight.h | |
parent | cea96c26d7185e3e46af5ff9497a6a240bd1a2a0 (diff) | |
download | crawl-ref-59cb47231f09c696c38ef72956e962c5b9cea191.tar.gz crawl-ref-59cb47231f09c696c38ef72956e962c5b9cea191.zip |
Calculated expected attack delay.
calc_your_attack_delay gets a scale parameter, and an implementation
of R_EXPECTED which is correct except for the hand-and-a-half plus
shield case, since I'm lacking a formula for the expected value
of min(1dN+1dK, 1dN+1dK).
Diffstat (limited to 'crawl-ref/source/fight.h')
-rw-r--r-- | crawl-ref/source/fight.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/crawl-ref/source/fight.h b/crawl-ref/source/fight.h index 5b8adc2724..06d7f89684 100644 --- a/crawl-ref/source/fight.h +++ b/crawl-ref/source/fight.h @@ -64,7 +64,9 @@ bool monsters_fight(monsters* attacker, monsters* attacked, bool wielded_weapon_check(item_def *weapon, bool no_message = false); int calc_your_to_hit(bool random_factor); int calc_heavy_armour_penalty(bool random_factor); -int calc_your_attack_delay(random_type rand, const item_def* weapon = NULL); +int calc_your_attack_delay(random_type rand, + int scale = 1, + const item_def* weapon = NULL); unchivalric_attack_type is_unchivalric_attack(const actor *attacker, const actor *defender); |