MCX211 Toggle Block
![]() | |
About | |
---|---|
ID | MCX211 |
Type | AISO |
Self Triggered | No |
Clickable | No |
Input | Yes |
Output | No |
![]() | |
First line | TOGGLE BLOCK |
Second line | [MCX211] |
Third line | id 1@code |
Fourth line | (X|Y|Z)(+|-)distance |
Craftbook Page |
The Toggle Block Craftbook IC toggles a block between two different types when the input is toggled.
This IC only works when the block in the specified space is one of the specified types. If another block type is in the way, you will get an error, "Toggle Block at (location) has a block in the way!" This does not disable the IC and will return to normal functioning when the intruding block is removed or replaced with one of the specified blocks.
There must also be a chest within 4 blocks with both the block to be swapped to next and room to receive the existing block. If the required block is not available or there is no room left, the sign will do nothing when toggled. Otherwise, the block in the chest will be swapped with the block in the chest.
If the sign passes the check, "TOGGLE BLOCK" will be written to the first line and you will be notified that a Toggle Block IC has been created. Otherwise, the sign will be blanked and you will get an error in chat.
Like the other block-moving ICs, MCX211 can swap stone into the world if there is cobblestone in the chest and will put stone in the chest if stone is swapped out of the world.
Details
First line
Leave blank when writing. Will be filled with "TOGGLE BLOCK" if accepted.
Second line
[MCX211]
Third line
The Item ID of the two block types to toggle between, separated by a pipe (|) character and "@data value", which defaults to zero if not specified. The first block type will be used when the sign is powered and the second will be used when the sign is not powered. Any of the standard Allowed Craftbook Block Types can be used.
Fourth line
The axis and offset of the space to toggle, from the block that the sign is placed on. First specify the axis (X, Y or Z), the sign (+ or -) and then the distance along chosen axis. You must always specify the axis and sign.
Examples
[MCX211] 1|5 Y+2
Swap the block two blocks above the block the sign is placed on between stone when on and wooden planks when off.
[MCX211] 5@1|1 X-2
Swap the block two blocks west of the block the sign is placed on between spruce planks when on and stone when off.
See also
- MCX208 Advanced Door
- MCX207 Advanced Bridge
- MCX206 (Flex Set) - Placed and optionally removes a block when toggled