/setblock EN

In this tutorial, we will look at how to use the /setblock command. It is very similar to the /fill command with the difference that /setblock places down or mines exactly one block.

/setblock

  • comand similar to /fill – places only one block

/setblock <coordinate> <material> <optional_attribute>

/setblock 132 76 -904 minecraft:redstone_block

/setblock 132 76 -904 air destroy (can be used to mine a block at a coordinate)

  • coordinate – relative or absolute coordinate
  • material – any block in Minecraft (including air)
  • optional_attribute – one of three options (usually not necessary, can be left out)
    • keep – places a block only if the current block at the given position is air
    • replace – always replaces the block at the given position, this is the default if the attribute is left out
    • destroy – if there is a block at the position it is mined as if it was destroyed by a player and replaced with the given block

If you want to build in the air, you can use this command to place a block at your feet (no need for a huge pillar) /setblock ~ ~ ~ stone

Leave a Reply