Posted 19 January 2015 - 10:25 PM
I am going to start by saying that this is my first real dive into ComputerCraft and programming in general (IT monkey by trade) so forgive me if i use the wrong terms or ask a dumb question.
I am looking into ComputerCraft as a possible solution to a problem we are having with our server.
ENVIROMENT:
Our server is a heavily modded server built around remote cities connected via rail lines to move goods and utilities to and from the Hub city (spawn). our server has no teleportation (ender chests, tesseract, etc) by design so our rail service is vital to our world. The server is set to reboot once per day if no one is on (so no set time). This helps with server stability.
ISSUE:
When the server is rebooted, any trains from RailCraft that are on train holding tracks or switch tracks become stuck or messed up (split, tangled, etc) which can completely shut down our system due to blocking the main rail lines.
POSSIBLE SOLUTION:
At this point I have set up a rail yard and a manual switch that will divert all trains to the rail yard and park them, at which point I can reboot the server then send all the trains back out (about 20 trains in total).
THE QUESTION:
Is there a trigger or hook that ComputerCraft can tie in to to know when the server is going to be rebooting so that it can trigger the trains to the rail yard. Additionally is there a way to have ComputerCraft fire back up after server reboot and be able to release all the trains. This would allow me to get the server back to a fully automated reboot cycle so i am not chewing up my time doing the manual service daily.
Thank you in advance for any input.
I am looking into ComputerCraft as a possible solution to a problem we are having with our server.
ENVIROMENT:
Our server is a heavily modded server built around remote cities connected via rail lines to move goods and utilities to and from the Hub city (spawn). our server has no teleportation (ender chests, tesseract, etc) by design so our rail service is vital to our world. The server is set to reboot once per day if no one is on (so no set time). This helps with server stability.
ISSUE:
When the server is rebooted, any trains from RailCraft that are on train holding tracks or switch tracks become stuck or messed up (split, tangled, etc) which can completely shut down our system due to blocking the main rail lines.
POSSIBLE SOLUTION:
At this point I have set up a rail yard and a manual switch that will divert all trains to the rail yard and park them, at which point I can reboot the server then send all the trains back out (about 20 trains in total).
THE QUESTION:
Is there a trigger or hook that ComputerCraft can tie in to to know when the server is going to be rebooting so that it can trigger the trains to the rail yard. Additionally is there a way to have ComputerCraft fire back up after server reboot and be able to release all the trains. This would allow me to get the server back to a fully automated reboot cycle so i am not chewing up my time doing the manual service daily.
Thank you in advance for any input.