Network Commands - minorDeveloper/mRail GitHub Wiki
A list of all relevant commands that can be issued to an mRail network
This should only be used for reference and is not guaranteed to be up to date with the latest version. (Last edited 2021/05/25)
Every command consists of the following (some may be nil
but this depends on the target program):
Parameter |
Description |
programName |
Type of program being run on the target device |
id |
id of the target device |
command |
The command type being issued, a string |
data |
Information accompanying the command, usually a table |
Block Controller oneway
The block controller is responsible for handling all one-way and bi-directional blocks on a network. There can be multiple block controllers, but each block on the network must have a unique blockID
Command |
Data Format |
Action |
Action if data is nil |
clear |
blockID(s) |
Clears block allocations and requests |
Clears all blocks |
clearAllocation |
blockID(s) |
Clears block allocation |
Clears all allocations |
clearRequest |
blockID(s) |
Clears block entry request |
Clears all requests |
clearTrain |
trainID |
Clears any blocks with the given trainID |
|
lock |
blockID(s) |
Stops new trains from entering the block |
Locks all blocks |
unlock |
blockID(s) |
Allows trains to start entering the block |
Unlocks all blocks |
block |
blockID, modifier (append , remove , replace ), name, entranceDetector(s), exitDetector(s) |
Edits the data about a block |
Any nil parameters are preserved |
entrDetector |
blockID, modifier, detector(s) |
Edits the entrance detectors for the block |
|
exitDetector |
blockID, modifier, detector(s) |
Edits the exit detectors for the block |
|
Detector detector
Command |
Data Format |
Action |
triggerRelease |
detectorID |
Authorises a detector to release a given train (does not notify the block controller) |
Depot Release depotRelease
Command |
Data Format |
Action |
dispatchTrain |
trainID, serviceID |
Releases a train from the given depot |
Platform Display platform
Tracking tracker
Dispatch dispatch
Station station
Network Controller network