// crit engine reduces speed // destroyed engine destroys CT public static bool Prefix(MechComponent __instance, WeaponHitInfo hitInfo, ComponentDamageLevel damageLevel, bool applyEffects) { try { if (!EngineCrits.ProcessWeaponHit(__instance, hitInfo, damageLevel, applyEffects, MechCheckForCritPatch.MessageAdditions)) { MechCheckForCritPatch.Message = null; return(false); } if (!Structure.ProcessWeaponHit(__instance, hitInfo, damageLevel, applyEffects)) { MechCheckForCritPatch.Message = null; return(false); } if (!Armor.ProcessWeaponHit(__instance, hitInfo, damageLevel, applyEffects)) { MechCheckForCritPatch.Message = null; return(false); } } catch (Exception e) { Control.mod.Logger.LogError(e); } return(true); }
// crit engine reduces speed // destroyed engine destroys CT public static bool Prefix(MechComponent __instance, WeaponHitInfo hitInfo, ComponentDamageLevel damageLevel, bool applyEffects) { try { EngineCrits.ProcessWeaponHit(__instance, hitInfo, damageLevel, applyEffects); } catch (Exception e) { Control.mod.Logger.LogError(e); } return(true); }