Difference between revisions of "Weapon Damage Formula"
imported>SnakeChomp m (clarify note) |
imported>SnakeChomp m (ArmCondtion ->ArmCondition) |
||
Line 38: | Line 38: | ||
:*fDamageArmConditionBase defaults to: 0.2 | :*fDamageArmConditionBase defaults to: 0.2 | ||
:*fDamageArmConditionMult defaults to: 0.8 | :*fDamageArmConditionMult defaults to: 0.8 | ||
:*When using a one handed weapon, '' | :*When using a one handed weapon, ''ArmCondition'' is 1 with a healthy right arm and 0 with a crippled right arm. | ||
:*When using a two handed weapon, ''ArmCondition'' is 1 with both arms healthy, 0.5 with 1 arm crippled, 0 with two arms crippled. | :*When using a two handed weapon, ''ArmCondition'' is 1 with both arms healthy, 0.5 with 1 arm crippled, 0 with two arms crippled. | ||
:With default values, this term reduces melee damage dealt by (up to) 10% of base weapon damage when arms are crippled and does nothing when arms are healthy. | :With default values, this term reduces melee damage dealt by (up to) 10% of base weapon damage when arms are crippled and does nothing when arms are healthy. |
Revision as of 21:47, 14 January 2009
This article is incomplete. You can help by filling in any blank descriptions. Further information might be found in a section of the discussion page. Please remove this message when no longer necessary. |
Gun Damage = PerkModifiers(BaseWeaponDamage * DamageMultiplier * GunConditionPenalty * SkillBonus) + CriticalDamageBonus
Melee Damage = PerkModifiers(BaseWeaponDamage * DamageMultiplier * MeleeConditionPenalty * SkillBonus + MeleeDamageActorValue + MeleeArmConditionPenalty) + CriticalDamageBonus
Unarmed Damage = Formula unknown at this time
PerkModifiers is a function that modifies the input value using any perks active on the actor that have a "Calculate Weapon Damage" Entry Point and returns the result. Note: consumables which increase damage, such as Yao Guai Meat, are implemented by adding a perk to the actor which has a "Calculate Weapon Damage" entry point for the duration of the effect.
BaseWeaponDamage is specified on the weapon form.
DamageMultiplier = fDamageWeaponMult
- fDamageWeaponMult defaults to: 1
GunConditionPenalty = fDamageGunWeapCondBase + (fDamageGunWeapCondMult * WeaponCondition)
- fDamageGunWeapCondMult defaults to: 0.34
- fDamageGunWeapCondBase defaults to: 0.66
- WeaponCondition is 1 at 100% condition, 0.5 at 50% condition, and etc
MeleeConditionPenalty = fDamageMeleeWeapCondBase + (fDamageMeleeWeapCondMult * WeaponCondition)
- fDamageMeleeWeapCondMult defaults to: 0.5
- fDamageMeleeWeapCondBase defaults to: 0.5
- WeaponCondition is 1 at 100% condition, 0.5 at 50% condition, and etc
SkillBonus = fDamageSkillBase + (fDamageSkillMult * ActorSkillValue / 100)
- fDamageSkillBase defaults to: 0.5
- fDamageSkillMult defaults to: 0.5
- ActorSkillValue is the actor's skill value with the weapon.
MeleeDamageActorValue is an ActorValue. The base value = fAVDMeleeDamageStrengthMult * (ActorStrengthValue + fAVDMeleeDamageStrengthOffset)
- fAVDMeleeDamageStrengthMult defaults to: 0.5
- fAVDMeleeDamageStrengthOffset defaults to: 0
- ActorStrengthValue is the actor's strength value
- The value of the MeleeDamage actor value can be increased or decreased by certain abilities, effects, perks, enchanted armors, and consumables. For example, the "Takoma Park Little Leaguer Cap" has an enchantment which increases melee damage by 5 while a baseball bat is equipped. Wearing this cap while equiping a baseball bat would mean that the base value calculated from strength is further increased by 5.
MeleeArmConditionPenalty = BaseWeaponDamage * (fDamageArmConditionBase - 1 + fDamageArmConditionMult * ArmCondition) / 2
- fDamageArmConditionBase defaults to: 0.2
- fDamageArmConditionMult defaults to: 0.8
- When using a one handed weapon, ArmCondition is 1 with a healthy right arm and 0 with a crippled right arm.
- When using a two handed weapon, ArmCondition is 1 with both arms healthy, 0.5 with 1 arm crippled, 0 with two arms crippled.
- With default values, this term reduces melee damage dealt by (up to) 10% of base weapon damage when arms are crippled and does nothing when arms are healthy.
CriticalDamageBonus = IsCriticalHit * PerkCritModifiers(CritDamage)
- IsCriticalHit is 1 if the attack was critical, 0 otherwise
- PerkCritModifiers is a function that modifies the input value using any perks active on the actor that have a "Calculate My Critical Hit Damage" Entry Point and returns the result.
- CritDamage is the "Crit Dmg" value on the weapon form
Notes
If weapon damage is calculated to be 0 before being modified by perks, the game engine considers the attack to have missed, even if the bullet physically impacts an actor. No blood spatter is made, no hit sound effect is played, and the attack cannot be a critical hit, even if the critical hit chance is 100% or more. However, if weapon damage is modified to be zero by a perk, the attack still has a chance to critically hit and any critical hits will do bonus damage.
Sneak attack damage
It is currently unknown how sneak damage modifiers are applied to the damage formula. Further research is needed. The variables involved appear to be:
- fCombatDamageBonusSneakingMult
- fCombatDamageBonusMeleeSneakingMult
- fDamageSneakAttackMult