OpenXcom Forum

Modding => Help => Topic started by: endersblade on October 19, 2019, 11:30:01 pm

Title: Help me understand damageModifier
Post by: endersblade on October 19, 2019, 11:30:01 pm
I'm not sure I understand how this modifier works.  Let's say for example I shoot an alien with 100 AP damage, and their AP damageModifier is 1.0, or 100%.  Does that mean they TAKE 100% of the damage, meaning all 100 points, or they NEGATE 100% of the damage, meaning they take 0? 

Or if I set all of an armor's damageModifiers to 0.0, anything with that armor would be invulnerable?  If I set it to 1.2, in the previous example the target would take 120 AP damage?
Title: Re: Help me understand damageModifier
Post by: krautbernd on October 19, 2019, 11:47:57 pm
Think of it as a multiplier for incoming damage - 1.0 means the damage it not modified, 0.0 means the damage is negated (i.e. multiplied by zero). So yes, if you set it to 1.2 the unit will take 120% of the incoming damage.

Keep in mind that damage is modified beforehand based on the used damage model (https://www.ufopaedia.org/index.php/Ruleset_Reference_Nightly_(OpenXcom)#Item_Damage_Types). So even if the weapon is supposed to deal 100 damage and the damage modifier is set to 1.0 the resulting damage might not be 100.
Title: Re: Help me understand damageModifier
Post by: endersblade on October 20, 2019, 12:13:36 am
Right, I was just using that as an example :-)  Thanks for the clear info!