User:JJ

WIP

Fallout 2 Ranged combat

Fallout 2 Ranged combat involves many compilcated formulas. The aim of this artice is not to dive in all the engine nuances, but to make them understandeble for an average (INT=5) player.

Chance to Hit
The equation below is a general equation for a Chance to Hit. The game takes into account many other factors, like blindness or lying target, also applies different bonuses for perception for PC and enemies, etc., which are not listed here. Chance to hit = (Weapon Skill + 8*(Perception - 2) + Weapon Perk - (4*Distance to Target) - Target AC + Lighting Penalty + STR requirement penalty + Aimed Shot Penalty) * (100 + Combat difficulty modifier) Note that penalties are negative numbers, so you subtract them.

Combat difficulty modifier is +20 on Wimpy and -20 on Rough; it affects only enemies.

Lighting penalty
Lighting penalties are determined as follows (in darkness): With Night Vision perk:
 * Target is 1 hex away: -0%
 * Target is 2 hexes away: -10%
 * Target is 3 hexes away: -25%
 * Target is 4 or more hexes away: -40%
 * Target is 1 hex away: -0%
 * Target is 2 hexes away: -10%
 * Target is 3 or more hexes away: -25%

Weapon Long Range perk
For any weapon with Weapon Long Range perk, the bonus from perception and the distance penalty is :

If Range < (PE-4)*2, only available when PE >= 5: ToHit = PE*8 ''Notice that if you are within a certain range, there is no distance penalty. Your Chance to Hit remains the same.'' If Range >= (PE-4)*2: ToHit = (PE-2)*16 - Range*4

Damage calculation
Below is an equation that tries to generalise the steps that the engine does to calculate damage. A = int(((weap_dmg + bonus_dmg) * (ammo_dmg_1 / ammo_dmg_2) * crit_multi) * (combat_diff / 100) - int(DT_armor / weap_pen) B = int((A * (DR_armor + DR_ammo)) Damage = A - B Function int is the same as trunc, it means to round down, for example int(4.7) = 4.


 * weap_dmg - random damage value produced from weapon's damage range
 * bonus_dmg - bonus damage from perks
 * ammo_dmg_1 - dividend of the ammo damage multiplier
 * ammo_dmg_2 - divisor of the ammo damage multiplier
 * crit_multi - critical hit damage multiplier from critical hit table
 * combat_diff - combat difficulty multiplier; Wimpy=75, Normal=100, Rough=125; does not influence player damage, only damage against the player
 * DT_armor - armor Damage Threshold
 * weap_pen - 5 - if weapon has Weapon Penetrate perk, 1 - otherwise
 * DR_armor - armor Damage Resistance
 * DR_ammo - ammo Damage Resistance modifier; total Damage Resistance is capped at 90%

Critical hit armor-piercing effect
An armor-piercing critical hit effect divides both DT and DR by 5 and (where applicable) rounding the result down. Weapons that already have the Weapon Penetrate perk do not gain an additional DT-reducing effect.

Weapon's ammunition DR modifier is factored in after the armor-piercing critical effect. This means that if the ammunition has a sufficiently negative DR modifier, an armor-piercing critical will negate 100% of the target's DR. Conversely, if the ammunition's DR modifier is poor (a large positive number), then DR will reduce a considerable percentage of even an "armor-piercing" critical hit's damage.

The positive DR modifier caused by the trait Finesse is nullified by the armor-piercing critical effect.

Merchants and stores
All merchants in the table below restock their wares.