Bridge Commander Central
BC Forums => BC Scripting => Topic started by: Billz on November 22, 2009, 05:50:17 AM
-
Is it possible to use the suns in BC to recharge power on ships by way of some kind of scripting?
Just thought it would be cool after watching 'Light' (SG:U season 1, ep 5).
-
Is it possible to use the suns in BC to recharge power on ships by way of some kind of scripting?
Just thought it would be cool after watching 'Light' (SG:U season 1, ep 5).
That's a good idea. I hope it's doable. If yes, I'd like to add this ability to the TIE Fighter and his/her brother/sister fighters which are at bcfiles.
-
It should be relative easy.
Get all Suns in the Set (I'm not sure how to do that best), get the Distance to all ships in the same set (with have Solar Panels or something set in their HP) (Like in FoundationTech: makeEnemeyShipList), calculate the Radiation Energy in that Distance (per Sun and Ship: Overall Energy by that Sun/(4pi*Distance) ) and set the BackupBattery to the actual Level plus the Radiation Energy ( pShip.GetPowerSubsystem.SetBackupBatteryPower() ). (More or less complicated, depending if you calculate the Radiation Energy per square meter multiplied with the Size of yuor SolarPanels multiplied with the efficency.
Ouh, and don't forget an Updater
-
Yea it's doable kinda like Krrks said.
Another thing tho: gotta check to see if it's a "real" sun object.
Because NanoFXv2 creates suns inside planets to give a glow effect with its AtmosphereFX feature. But with a bit clever scripting it's easy to check those (mainly because of their names). GC/GravityFX does that.
Also, the Destiny recharges itself by literally "surfing" a star, she doesn't just pass close to it, she doesn't have "solar panels" in the real sense.
And in the ST universe, except for some really small craft (like shuttles, or not even that...), having solar panels to get power from a star, as close as it could be, would most likely still not be enough to even recharge the batteries efficiently (that is, in a good amount of time and so) to be of any use.