magic/marksman/steadfast clarifications
Moderator: Forum Moderators
magic/marksman/steadfast clarifications
How is the calculation done when a steadfast unit defends against an magic attack or unit with marks(wo)man?
Wich rule applies? Allways double defence up to 50% or always 70/60% chance to hit?
How is the marskman/magic used when defenders have less than 30/40 defence is 70/60 cth used anyway?
/tsr
Wich rule applies? Allways double defence up to 50% or always 70/60% chance to hit?
How is the marskman/magic used when defenders have less than 30/40 defence is 70/60 cth used anyway?
/tsr
Resistances, not defense.Wesnoth wrote:"Steadfast: This unit's resistances are doubled, up to a maximum of 50%, when defending. Vulnerabilities are not affected."
Either 60% or defender's natural defense, whichever grants better CTH.Wesnoth wrote:"Marksman: When used offensively, this attack always has at least a 60% chance to hit."
Straightforward. Always 70%.Wesnoth wrote:"Magical: This attack always has a 70% chance to hit."
1. Steadfast doubles resistance, not defence, so steadfast has no connection with marksman/magic
Magic attacks always has 70% CTH, regardless of defender's defence.
Marksman attacks has at least 60% in offence.
Action Def Magic Marks
Attack 50% 70% 60%
Defend 50% 70% 50%
Attack 20% 70% 80%
Defend 20% 70% 80%
Def = Defence of enemy
Magic = CTH using magic attack
Marks = CTH using marksman attack
Did I answered you question?
Magic attacks always has 70% CTH, regardless of defender's defence.
Marksman attacks has at least 60% in offence.
Action Def Magic Marks
Attack 50% 70% 60%
Defend 50% 70% 50%
Attack 20% 70% 80%
Defend 20% 70% 80%
Def = Defence of enemy
Magic = CTH using magic attack
Marks = CTH using marksman attack
Did I answered you question?
- Viliam
- Translator
- Posts: 1341
- Joined: January 30th, 2004, 11:07 am
- Location: Bratislava, Slovakia
- Contact:
I tried to read and understand the some source files, so there are results of my (incomplete) reading:
The damage calculating algorithm in pseudocode:
If I understand it correctly, all bonuses to damage are multiplicative (that is, they never say "add X damage", only "add X% damage"), so their order in algorithm is not important.
The damage calculating algorithm in pseudocode:
Code: Select all
if your attack is MAGICAL
chance to hit is 70%
if your attack is not magical
chance to hit depends on opponent unit type and terrain
but if you are MARKSMAN, it is at least 60%
base damage depends on your weapon
if you have BACKSTAB
and you are attacking
and backstab conditions are fulfilled
double the damage
if you or opponent have CHARGE
and the one with charge is attacking
double the damage
if you are LAWFULL / CHAOTIC
add/remove the time bonus % to/from damage
if your friendly unit on adjacent field has LEADERSHIP bonus
and it has higher level than you
add leadership bonus % to damage
(if given multiple leadership bonuses, use only the highest one)
if opponent unit has STEADFAST
remove double resistance % from damage
if opponent unit does not have steadfast
remove resistance % from damage
if you are SLOWED
remove 50% from damage
if you have DRAIN
after successful attack you receive 50% of damage as hitpoints
if you or opponent have BERSERK
and both are alive
and not already fighting 30 rounds
fight again
if you have PLAGUE
and you killed your opponent
and plague conditions are fulfilled
a new walking corpse unit is created
- Viliam
- Translator
- Posts: 1341
- Joined: January 30th, 2004, 11:07 am
- Location: Bratislava, Slovakia
- Contact:
Some consequences:
If your attack is MAGICAL and your unit is MARKSMAN, it has exactly 70% chance to hit.
Please note that magical attack makes marksmanship useless... unless the unit can use the marksman ability to some other, non-magical attacks.
If you attack someone with CHARGE and BACKSTAB (and there is your friend on the opposing side of the defending unit); and you are LAWFUL during the day; and you are first level unit and there is a third level unit with LEADERSHIP on adjacent hex, and you use a holy attack against undead unit (resistance -100), and your base damage is 5, total damage would be:
However, if you have none of the abilities described above; you are LAWFUL during the night, SLOWed, and you use a holy attack against a STEADFAST dwarf with resistance 20, and your base damage is 5, total damage would be:
Moral of the story? Well... it gives you some insight on what to do and what to avoid when you are lawful unit with holy attack, I suppose.
If your attack is MAGICAL and your unit is MARKSMAN, it has exactly 70% chance to hit.
Please note that magical attack makes marksmanship useless... unless the unit can use the marksman ability to some other, non-magical attacks.
If you attack someone with CHARGE and BACKSTAB (and there is your friend on the opposing side of the defending unit); and you are LAWFUL during the day; and you are first level unit and there is a third level unit with LEADERSHIP on adjacent hex, and you use a holy attack against undead unit (resistance -100), and your base damage is 5, total damage would be:
Code: Select all
5
× 2 // charge
× 2 // backstab
× 1.25 // +25% lawful in day
× 1.50 // +50% leadership 2 levels higher
× 2.00 // -100% resistance
= 75
Code: Select all
5
× 0.75 // -25% lawful in night
× 0.50 // -50% slowed
× 0.60 // -2×20% steadfast + resistance
= 1.125
Moral of the story? Well... it gives you some insight on what to do and what to avoid when you are lawful unit with holy attack, I suppose.
Some little addition to Viliam's:
MARKSMAN works only when attacking
Code: Select all
if your attack is not magical
chance to hit depends on opponent unit type and terrain
but if you are MARKSMAN AND you are attacker, it is at least 60%
- Elvish_Pillager
- Posts: 8137
- Joined: May 28th, 2004, 10:21 am
- Location: Everywhere you think, nowhere you can possibly imagine.
- Contact: