BattletechModders / MechEngineer

Mod for BattleTech that introduces many CBT mechanics to the MechLab
GNU Lesser General Public License v2.1
11 stars 21 forks source link

Request: Extension for max possible hits detection on components #181

Closed IceRaptor closed 4 years ago

IceRaptor commented 4 years ago

I'm writing a new mod that is intended to represent damaged or salvaged mechs by randomly damaging components and structure. For ME components, it would be helpful to have an extension on the MechComponent that I could call to determine the maximum number of hits an item could take. This way I could prevent killing a unit before it even spawns by limiting engine or gyro hits to max - 1.

I would normally limit total hits to 1, but BloodyDoves has implemented primitive engines with 1 crit as a critical component. Being able to detect RT primitives vs. BTA primitives requires a check of total possible damage.

Thank you in advance!

CptMoore commented 4 years ago

get CriticalEffects custom component and then just .MaxHits