Right now ive been messing around with the scripts that control what stats a shipsystem changes while active, so as the mod im developing needs new interesting shipsystems, that aren't even close to any existing system on vanilla, i've found some problems where i don't understand what im changing due to the naming leads me to one stats, but its actually another completely different or simply doesn't do anything making me go
An example:
Heal % amount of hp from total at a flux cost;
Flux cost is done inside the shipsystem.csv
the AI is responsible to make sure NOT to use it when i don't have enough flux (and other things)
and now for the script...
with the help of LazyWizard, the methods responsible in changing hp when the system is clicked are:
stats.getMaxHullRepairFraction().modifyFlat(id, 0.5f);
stats.getHullRepairRatePercentPerSecond().modifyFlat(id, 0.5f);The first would give me the max amount of hull i want to repair
The second would give me the rate in % i want it repaired so for example
if the first i want 20% then that would be 20% from total of the amount i want repaired
the second would be how much % i want repaired per sec, if i wanted 10% that would be 10% from those 20% repaired every second (thats hull 2% repaired every second)
Now lets see what my Podship from the UQM second ability is:
From:
http://wiki.uqm.stack.nl/PodshipFour Mycon are revived in an instant, but the process consumes the Podship's entire combat battery.
Converting 4 crew in hp would exactly 20% of hull hp
After setting the script, pointing the *.system file to the script and adding the cost in flux on the shipsystem.csv i gave it a try. even with my hull at around 1% the system did not heal back so... what exactly am i doing wrong...