diff --git a/code/modules/atmospherics/machinery/components/fusion/hfr_main_processes.dm b/code/modules/atmospherics/machinery/components/fusion/hfr_main_processes.dm index 0e6e899778c..97d61b51103 100644 --- a/code/modules/atmospherics/machinery/components/fusion/hfr_main_processes.dm +++ b/code/modules/atmospherics/machinery/components/fusion/hfr_main_processes.dm @@ -457,8 +457,10 @@ // If we have a preposterous amount of mass in the fusion mix, things get bad extremely fast if(internal_fusion.total_moles() >= HYPERTORUS_HYPERCRITICAL_MOLES) - var/hypercritical_damage_taken = max((internal_fusion.total_moles() - HYPERTORUS_HYPERCRITICAL_MOLES) * HYPERTORUS_HYPERCRITICAL_SCALE, 0) - critical_threshold_proximity = max(critical_threshold_proximity + min(hypercritical_damage_taken, HYPERTORUS_HYPERCRITICAL_MAX_DAMAGE), 0) * seconds_per_tick + var/moles_over_limit = internal_fusion.total_moles() - HYPERTORUS_HYPERCRITICAL_MOLES + var/hypercritical_damage_taken = max(moles_over_limit * HYPERTORUS_HYPERCRITICAL_SCALE, 0) + hypercritical_damage_taken = min(hypercritical_damage_taken, HYPERTORUS_HYPERCRITICAL_MAX_DAMAGE) * seconds_per_tick + critical_threshold_proximity = max(critical_threshold_proximity + hypercritical_damage_taken, 0) warning_damage_flags |= HYPERTORUS_FLAG_HIGH_FUEL_MIX_MOLE // High power fusion might create other matter other than helium, iron is dangerous inside the machine, damage can be seen