Stock SignalReactions.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
door(
Map< int, int> closedToOpen, {void onSwing(IVec3 lower)?}) → SignalReaction -
A two-high door:
closedToOpenpairs its states; both halves open together when either is powered.onSwingafter the lower half turns. Register it for every closed and open id. -
piston(
Map< int, int> retractedToExtended, {required IVec3 facing(int id), required bool pushable(int id), required bool givesWay(int id), void onExtend(IVec3 lower)?}) → SignalReaction -
A piston:
retractedToExtendedpairs its states,facingis the way a state pushes. Powered, the block in front moves one cell on when the cell past it gives way (givesWay) and the block ispushable; a blocked piston stays retracted. Unpowered, the head pulls back (nothing is pulled). Register it for every state. -
poweredRun(
Map< int, int> offToOn, {int reach = 8}) → SignalReaction -
A run of powered rails (or any line of blocks):
offToOnpairs the states. The run is the blocks joined on the four sides from the cell (capped at 64); every one withinreachsteps along it of a powered one is on. Register it for every state. -
swap(
int off, int on) → SignalReaction -
A lamp:
offwhen unpowered,onwhen powered. Register it for both ids. -
trigger(
void then(IVec3 cell)) → SignalReaction -
Calls
thenwhile powered (TNT lit by a wire).