Logic
/File/en/Notice.png
Note
These might be not optimal solutions, but I haven't yet seen better ones.

Contents

Prelude

One day I thought - we have logical OR, why don't make logical NOT and AND? It's... challenging.

(Here and afterwards I assume green color asTRUEand red asFALSE)

OR

Arguments are TRUE/TRUE

The basic OR is simply created by a one pre-entry signals and two pre-exit signals.

TRUE/FALSE

FALSE/TRUE

FALSE/FALSE


NOT

Argument set to TRUE

This looked easy at first, but it took a long time to create this structure.

Here n1 and n2 are the stations for maglev to run between. (Orders set to "Non-stop", TTDPatch compatible non-stop handling set to "on"). Notice, that n1 has two platforms. This is why we can't use Waypoints, and this is why we need TTDPatch compatible non-stop handling.

a and b are Signals, they stop the train, if argument is FALSE and move him out of the track.

x and y collect the position of the train and close the result signal. Unfortunately, I've found out a little bug in this scheme. At some times, it File:en/Logic.not bug.png.

Argument set to FALSE


AND

Arguments are TRUE/TRUE

One solution was to make A AND B as NOT((NOT A) OR (NOT B)), but that would be messy, so I have found out another solution.

Here a1 and a2 are the stations for maglev to run between. (Orders set to "Non-stop", TTDPatch compatible non-stop handling set to "on"). Notice, that both stations have two platforms. This is why we can't use Waypoints, and this is why we need TTDPatch compatible non-stop handling.

a and b are Signals (so are aa and bb), they stop the train, if argument is FALSE and move him out of the track.

x and y collect the position of the train and close the result signal.

Unfortunately, I've found out a little bug in this scheme, too. At some times, it File:en/Logic.and bug.png.

Other possible situations:

TRUE/FALSE

FALSE/TRUE

FALSE/FALSE