-
Notifications
You must be signed in to change notification settings - Fork 46
Documentation
One of Redstone Tools' biggest features is the macro system it adds. The macro system allows users to increase their productivity by allowing users to press a keybind to quickly run a command or list of commands. Below is a guide on how to get started using macros.
To add, edit, delete, disable/enable or simply inspect macros, you have to open the macro menu. To do this, open the main menu (escape) and go to Options... -> Controls... -> Macros...
, use the keybind, or simply run /edit-macros
. Once you're in the macro menu you'll be able to:
- Edit macros by clicking the
Edit
button next to the macro you want to edit. - Delete macros by clicking the
Remove
button to the macro you want to delete. - Create a new macro by clicking the
Add macro
button. - Drag and drop a .txt file to add the contents of the .txt file as a new macro
Once you're editing a macro you'll have the option to change its name, keybind, commands, and its muted and enabled status. You can also use advanced keybind settings by clicking its icon next the hotkey.
Redstone Tools adds gamerules to help users configure their worlds just the way they like them, below is a list of all gamerules added by Redstone Tools and what they do.
Whether or not containers should drop their items when they're broken, defaults to true.
Redstone Tools has a few configurable options. Below is a list of these options.
The string that is used to denote the start of a variable
The string that is used to denote the end of a variable
The string that is used to denote the start of a math expression
The string that is used to denote the end of a math expression
Runs the first time you join a world/server in this session
Runs every time you join a world/server
Runs every time you change dimension
When pressing this hotkey, will open the config menu, defaults to V+C
When typing "/give @s redstblock" in chat, with this disabled it will give no suggestions (default behaviour, or "prefix matching"), but with this enabled it will give "redstone_block" as a suggestion (so called "fuzzy matching"), defaults to true.
Whether to show the block outline when airplace is enabled, defaults to true.
How tall the redstone dust hitbox should be when bigdust is enabled. Can be from 0 (flat) to 16 (full block), defaults to 3.
Whether or not to enable Airplace. Triggering the hotkey will toggle Airplace.
Whether or not to enable Autodust. Triggering the hotkey will toggle Autodust.
Whether or not to enable Autorotate. Triggering the hotkey will toggle Autorotate.
Whether or not to enable Bigdust. Triggering the hotkey will toggle Bigdust.
Whether or not to enable Clickcontainers. Triggering the hotkey will toggle Clickcontainers.
Redstone tools adds some nifty features to the chat. This part assumes you have everything set to default.
Variables allow for certain strings to be replaced with others.
Note that, even though the formatting in the chatbox may not always work how you'd expect, variables will always be inserted into commands.
Also note that variables will not work in normal chat messages.
Given these commands have been run in order:
/clientdata set gm gamemode
/clientdata set s say
/clientdata set var \'gm'
/clientdata set m turnOn
/clientdata set toggleMacro macro \'m'
If the literal string 'gm'
is found in a command, it will get replaced by its value
'gm' creative
-> gamemode creative
You can escape variables by using a backslash (\
)
\'gm' creative
-> 'gm' creative
You can stack variables
'var' creative
-> gamemode creative
If you make a macro M that executes /'var' creative
, then do /clientdata set var \'s'
, running M will execute /say creative
[^1]. If you then do /clientdata set var \'gm'
, running M will execute /gamemode creative
[^2].
You can do math expressions
{1 + 3}
-> 4
It supports +
, -
, *
, /
, ^
and parentheses. Spaces don't matter
You can use variables with commands
Given these commands have been run in order:
/clientdata set x 2
/clientdata set y 4
/clientdata set addXY {\'x' + \'y'}
Now, doing /g stone 'addXY'
will give you 6 stone
If you now do /clientdata set x 4
, running /g stone 'addXY'
will give you 8 stone
Say you want to put this into macros
/print hello!
if (condition) {
/print true
} else {
/print false
}
/print whats up
You could do the following
macro setConditionTrue:
/clientdata set condition macro onTrue
macro setConditionFalse:
/clientdata set condition macro onFalse
macro onTrue:
/print true
macro onFalse:
/print false
macro whatever
/print hello
/'condition'
/print whats up
Now, if you run /macro setTrue and then /macro whatever, it'll print
hello!
true
whats up
If you do /macro setFalse and then /macro whatever, it'll print
hello!
false
whats up
You can do else if too
if (condition1) {
/print condition is true
} else if (condition2) {
/print condition2 is true
} else {
/print both are false
}
By just rewriting it a bit
if (condition1) {
/print condition1 is true
} else {
if (condition2) {
/print condition2 is true
} else {
/print both are false
}
}
Or just if too
if (condition1) {
/print condition is true
}
By rewriting it again
if (condition1) {
/print condition is true
} else {
}
Redstone Tools adds a bunch of commands to improve productivity. Below is a list of the names of all commands added by Redstone Tools and what they do.
Client side - Since v3.1.0
Prints something to the chat.
What to print
Client side - Since v3.1.0
See variables
The variable of the name.
What to set the variable to.
Client side
Runs a macro.
The name of the macro to run.
Client side - Since v3.1.0
Runs a macro.
The name of the macro to run.
Client side - Since v3.1.0
Opens the settings menu.
Server and client side
Teleports you distance
blocks in the direction you're looking or to the block you are looking at if it's closer.
If after 10 seconds it is still calculating where you should end up, it will cancel the teleport.
The distance to teleport you in blocks, defaults to 50.0.
Whether to teleport to a fluid you're looking at if it's closer than distance
, will let you teleport through fluids if set to true, defaults to false.
Whether to reset your velocity to 0 after teleporting, defaults to true.
Server and client side
Converts a number to a different base and outputs it.
The number to convert, e.g. 0b1001, 0xffe2, 0o25, 0d123 or 123.
The base to convert number
to, e.g. 10.
Server and client side - Since v3.0.0
Changes your default reach.
The distance in blocks to set your block and entity reach to.
Server and client side - Since v3.0.0
Shorthand for the vanilla /give @s.
The item to give.
The amount to give, defaults to 1.
Server side
Gives you an exact copy of the block you're looking at including it's NBT data.
Server side
Gives you a block of the specified type with the color of the block you're looking at.
The block type. Can be concrete, glass, terracotta or wool.
Server side
Gives you a container that outputs the specified signal strength.
The signal strength the barrel should output, defaults to 15.
The container type to give you, defaults to auto meaning it'll be a barrel.
Server side
Binds the next command you run to the item you're holding.
If true, will remove the currently bound item.
Server side - Since v3.1.0
Shows the item components of the item in your main hand.
Whose main hand to use.
For toggles that have settings (Currently /airplace
and /bigdust
) their settings can be found in the config menu, accessible by pressing the Hotkey to open menu
hotkey
Client side
Lets you place blocks in the air if there is no block in reach.
Client side
Makes the redstone dust hitboxes bigger.
Server side
Automatically places redstone dust on colored blocks such as wool and glass that you place.
Server side
Automatically rotates rotatable blocks by 180 degrees.
Server side - Since v3.0.0
Increases the level of cauldrons and composters by one when right-clicking them with an empty hand.
Server side
Converts all colored blocks such as wool and glass in your selection to the given color.
The color to convert the selected blocks to.
If set will only color the blocks with this color. For example, if onlyColor
is red only red blocks will be recolored.
Server side
Stacks your selection with a custom distance.
The amount of times to stack your selection, defaults to 1.
The direction to stack your selection in, defaults to me (the direction you're looking in).
The offset between copies. 1 means 0 air gaps in between, 2 means one air gap in between, defaults to 2.
Whether or not to move the selection to the last pasted position.
Server side
Minimizes your selection by removing surrounding layers consisting of only air. Note that this might not work with some selection visualisers like //drawsel.
Server side
Interprets your selection as a binary number and outputs it. First position is the MSB.
The offset between tested blocks, defaults to 2.
The block that represents a 1 bit. Otherwise, if it doesn't match, it will be a 0 bit, defaults to redstone_lamp[lit=true] (a lit redstone lamp).
The base to output the value of the binary number in, defaults to decimal.
Whether the bits are in reverse, defaults to false.
[^1]: /'var' creative
-> /'s' creative
-> /print creative
[^2]: /'var' creative
-> /'gm' creative
-> /gamemode creative