That said, if anyone stumbles upon the $defencestrength or $target.boardingresistance algorithms in the code available to us, would very much appreciate it if you could post it, and its location, here.
Mods, please feel free to move or merge this where you deem appropriate, but I would like to request that it stay within the Scripts and Modding forum since there would likely (hopefully!) be a better chance of a modder stumbling upon that algorithm, and stumbling upon this thread, and posting here.
Had a pleasant afternoon testing today. By no means exhaustive, but these are what I found pertinent to defence strength or boarding resistance so far. Just a quick data dump for now. Will edit to something more readable if it proves interesting to anyone.
_____
$defencestrength factors
cargo - no
DO/Captain/Engineer - none, unless needs zone reset to update (my test subject kept dying after I leave, then move back to the zone where it was)
DRONES (does not take DO influence into account)
(no. of drones of a type * type multiplier + $defencestrength)
cargolifter drones - 1
construction urv - 1
scooper mk1 - 0.7
scooper mk2 - 2.5
miner - 0.6
miner mk2 - 2.367
assault urv - 2
interceptor - 0.7
interceptor mk2 - 3
intrepid - 1
intrepid mk2 - 4.167 (4 and 1/6th)
overrun - 1.3
overrun mk2 - 5.1
If any number of drones of a particular type are deployed, NONE of the drones of that type contribute to defence strength. So if, for example, 30 interceptor drones mk1 are present, and 4 are deployed, no interceptor drones mk1 contribute to defence strength.
NB: do NOT try to put xenon drones in a Titurel
_____
NOT TESTED:
hull damage (precise proportion)
surface element/s (type and number)
DO/Captain/Engineer with zone reset (can someone with a fleet please test this? Mine is in Twilight Sentinel in v2.51

ammunition