started re-implementing route reservation

This commit is contained in:
Stephan Richter
2021-03-10 01:21:10 +01:00
parent 966c5340ba
commit 830c1863ad
17 changed files with 284 additions and 291 deletions

View File

@@ -159,7 +159,7 @@ public abstract class Turnout extends Tile implements Device{
}
public Reply state(State newState) {
if (train != null && newState != state) return new Reply(415, t("{} locked by {}!",this,train));
if (is(Status.LOCKED,Status.OCCUPIED) && newState != state) return new Reply(415, t("{} locked by {}!",this,train));
if (address == 0) {
state = newState;
plan.place(this);