This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
Jac0b's profile picture

[BigReactors] Reactor Status

Started by Jac0b, 28 May 2015 - 06:38 PM
Jac0b #1
Posted 28 May 2015 - 08:38 PM
Hi, after some struggles with the Big Reactors mod, I've decided to make a simple program, that shows the reactors' status on the connected monitor and shuts the reactor down, when the energy buffer is on 90% (and turns it back on, when it's under 90%)

It is published under the MIT license, that basically means you can do whatever you want with it, as long as you credit me and share it under the same license…




VERSION 1.5
Changelog:
- Added configuration values for minimal and maximal amount of energy stored in the buffer
- Made the configuration more user-friendly
- Fixed some bugs
- Runs more stable

Known bugs:
- None!

To Do:
- More languages
- Interactive settings/installer
- Setting sides on the go with command args




Screenshot
Spoiler

Update Guide
Automatic updater is comming soon!
1. Delete the old version by typing rm reactor
2. Download the new version by typing pastebin get uWHJ5xwW reactor
3. Edit the configuration again
4. (Optional) Make it start with the system by typing mv reactor startup
5. Profit!

Installation Guide
To use, simply add one Reactor Computer Port to your reactor and place a computer next to it (you can also use the Networking Cables). Then place a 2 by 3 monitor next to the computer. (I recommend using Advanced Computers, as they support colors!)

Automatic installer is comming soon!
1. Download the program by typing pastebin get uWHJ5xwW reactor
2. Edit the configuration (top-most portion of the program, you can open it for editation by typing edit reactor)
3. (Optional) Make it start with the system by typing mv reactor startup
4. Profit!

If you have any suggestions for features or you find a bug, please let me know ;)/>
Edited on 29 May 2015 - 09:26 AM
Bomb Bloke #2
Posted 29 May 2015 - 12:00 AM
Consider doing something like this up the top of the script:

-- Set this to the side on which your reactor is connected
local r = peripheral.wrap("right")
while not r.getConnected() do sleep(10) end

This should help make the script more stable when starting while the reactor's chunk is loading (eg during a server restart). You may find it randomly crashes at boot otherwise.

Personally, I like to have my reactor turn on at 10% capacity, and shut down at 90%. You might consider storing these values in variables defined up the top of the script, making them easy to edit.

You seem to be missing a pipe symbol at 15x11?

Your reactor would heat slower with a better coolant fluid. Melting down ender pearls gets the best results, IIRC.
Jac0b #3
Posted 29 May 2015 - 10:00 AM
Okay, thanks, I'll fix it ;)/> And the pipe symbol, where exactly?

Also for the coolant, the screenshot is from our private survival server and we don't have that advanced tech yet…
flaghacker #4
Posted 29 May 2015 - 05:41 PM
And the pipe symbol, where exactly?

Bottom center, Bomb Bloke told you the coordinates.
Parzivail #5
Posted 02 June 2015 - 03:35 AM
Just a thought, you could probably change
sleep(0.25)
at line 170 to
sleep(1)
and still be fine. The reactor really won't respond any more efficiently at 1/4s than at 1s AFAIK =D