Cannot figure out how that works. Timer probably is self explanitory. Timer goes off 20 times a second, due to it advancing with the combat simulation, and manages overflow of duration. Hence, this should run 20 times a second. I cannot figure out how to implemented it. It would be benfitial however, considering it should reduce how often calculations are made.
However, I don't see what setting the Mult to zero every time is for, unless it resets, or only effects a copy for this particular gameloop.
As for 0.001f, being 1/1000th in float format. Well, unless getMaxFlux works very differently from how I think it does, or other factors are involved (that ship spreadsheet that has multipliers), then that is clearly wrong.
The Hammerhead has an upkeep of 100 for 4200 flux, while the shuttle has an upkeep of 75 for 1600 flux. This makes it pretty obvious that it is not simply a fraction of the total.
Hammerhead, 4200 * 0.001 = 42; 42/100 = .42
Shuttle , 1600 * 0.001 = 16; 16/ 75 = .21_6_
I would expect to get very nearly the same value there.
The spreadsheet gives a 0.5 modifier for the shuttle, and 0.4 for the hammerhead, which is nowhere near enough to make up the difference.
Presumably I missed something somewhere.