Class DefensePenetrationFnSO
- Assembly
- com.electricdrill.astra-health.Runtime.dll
Base type for defense penetration functions. Implementations compute a reduced defense value based on a piercing stat and the pierced defense stat.
public abstract class DefensePenetrationFnSO : ReductionFnSO, ITaggable
- Inheritance
-
objectDefensePenetrationFnSO
- Implements
-
ITaggable
- Derived
- Inherited Members
Methods
CalculatePiercedDefense(long, long, StatSO, bool)
Compute the reduced defense value after applying a piercing stat.
public abstract double CalculatePiercedDefense(long piercingStatValue, long defensiveStatValue, StatSO defensiveStat, bool applyClamp = true)
Parameters
piercingStatValuelongThe attacker's piercing stat value used to reduce defense.
defensiveStatValuelongThe defender's original defense stat value to be reduced.
defensiveStatStatSOThe defensive stat object used to clamp the result within its min/max bounds.
applyClampboolWhether to apply stat clamping to the result. Default true for normal gameplay; false for analysis/graphs.
Returns
- double
The reduced defense value (clamped if applyClamp is true).