From SylphicXen's comment on https://steamcommunity.com/sharedfiles/filedetails/?id=2498906212
Might I suggest a possible way to estimate the block count of armor? If you can accurately get the counts of functional blocks that are exposed to in-game scripting, you can subtract their combined weights (since weights of default blocks at the very least don't change) and guess that the nonfunctional blocks are light armor or heavy armor, depending on user choice.
It won't be accurate, but perhaps it can be an alternative for people who don't want to look up the block count in info, and/or don't need a completely accurate estimation of the score.
You can even provide a prefix to the result like โ to show that it's not completely accurate.
Good idea!
The grid would need a cockpit (IMyShipController
) so we can call .CalculateShipMass()
and use BaseMass
. We'll need a big table to subtract each terminal block mass (I'll need to find that somewhere, maybe you have a link already?), then we can make a guess how many armor blocks is the rest. We could even provide a range of worst/best case, from smallest light armor to biggest heavy armor.
Also the good news is that the total block count has a minor effect on the threat score compared to the other blocks because the total block count is divided by 100 (code), so in practice I don't expect a large swing on the final threat score.
I don't know if or when I'll implement this, but tracking the idea in this issue.