A super simple way to modify your ship for automated energy/fuel management with YOLOL code in Starbase.
You can easily modify your ship to save tons of energy and avoid having to replace fuel rods on a regular basis. With a simple script written in YOLOL, Starbase’s programming language, your ship generator will turn on and off automatically based on battery charge and regulate how much output is currently required.
It’s a simple solution to avoid having to manually turn the generator on and off whenever the ship comes to a halt.
- A ship equipped with a generator and battery.
- A YOLOL Chip Socket
- A Basic YOLOL Chip
- Cable and bolt tools
These can be obtained from the auction house or made by hand on a crafting bench.
Install the YOLOL Chip
Using the bolt tool, attach the YOLOL Chip Socket to a beam on your ship. After that, insert the Basic YOLOL Chip into the Socket. Finally, use the cable tool to connect the Socket to the generator network.
Program the YOLOL Chip
Press the center lock and slide it down to edit the YOLOL script inside the chip. Insert the following code into the first line.
:FuelChamberUnitRateLimit=100-:StoredBatteryPower/100 goto 1
If you want, you can always rename the device fields FuelChamberUnitRateLimit to GeneratorOutput and StoredBatteryPower to BatteryCharge. In fact, they should have similar names in the YOLOL script and on your ship’s battery and generator fuel chamber. Use the universal tool to rename device fields. To edit, press u while pointing at the device, then go to the Data tab.
And that concludes this Starbase guide. Do you have any suggestions to improve this guide? Please let us know by leaving a comment below. For any other concerns, please reach us using the contact details found on the contact page.