You are right, but I am not sure if resistance aplies after treshold or vice versa. Could be good to know the damage formula for sure.
assuming normal difficulty levelif finesse is present then finesse_mod=30, otherwise finesse_mod=0if armor bypassed critical, and the damage type is not emp: dt = armor_dt/5; dr = armor_dr/5 + dr_mod // finesse is skipped in this caseif not armor bypassed critical or armor bypassed with emp, but armor piercing or weapon penetrate perk: dt = armor_dt/5; dr = armor_dr + dr_mod + finesse_modif none of above: dt = armor_dt; dr = armor_dr + dr_mod + finesse_modif dt<0 then dt=0if dr<0 then dr=0if dr>100 then dr=100totaldamage=0dmg_mul = ammo_dmg_mul*global_dmg_mul // usually global_dmg_mul=2, but can be modified by criticals; see Kanhef's entry on critical hit tables at falloutmods wikidmg_div = ammo_dmg_div*2if attack is ranged, but not throwing bonus = 2*bonus_ranged_damage_levelotherwise bonus = 0for every bullet that hit: rawdamage=Rnd(weapon_dmg_min, weapon_dmg_min) + bonus rawdamage*=dmg_mul; rawdamage/=dmg_div; rawdamage-=dt rawdamage-=(rawdamage*dr)/100 if rawdamage > 0 then totaldamage+=rawdamageif living anatomy is present, and the target is neither robot nor alien totaldamage+=5if pyromaniac, and weapon damage type is fire totaldamage+=5