Here's the structure of the /setblock
command:
/setblock x y z block data method [dataTag]
xyz
are the coordinates of the block
block
is the TileID of the block (includes id:0 now!)
data
is the block data (i.e. 5:1 spruce wood)
method
is one of three things: keep
, replace
, or delete
keep
spawns the block at the coordinates.
replace
replaces the block at the coordinates with the block ID.
delete
removes the block at the coordinates and then spawns the new one in
dataTag
(optional) is tile entity data.
From Minecraft wiki
If you're trying to clear all item drops in the world, you can run:
/kill @e[type=item]
which will kill all dropped items in the world. However, there are slightly better ways of doing this. Namely, only clear items within a radius of x blocks from the command block. This preserves drops elsewhere, but still clears the first item:
/kill @e[type=item,r=x]
Additionally, if you want to ensure that something can only be triggered once, place an input stabilizer on it:
![](https://i.imgur.com/Bc1dlqx.png)
This device will "lock" the redstone state to ON, even after the item is removed. It cannot be re-triggered unless you manually break the redstone.
You can expand on this by only making it hold one pulse if so needed.
Best Answer
There is no command to change all stained glass in the entire world, but you can use
/fill
withreplace
to replace blocks of a certain type in an area with a different blocks.This command would replace all white stained glass in the selected area with regular glass:
Your situation is a bit more difficult, because you want to change more than one type of blocks at once. You could repeat the command from above for all types of stained glass, but you would need 16 commands for that.
Minecraft has an
impermeable
-tag that happens to include all solid forms of glass (no glass panes). You can use that instead to change all types of glass at once: