How to use WorldEdit with Modded Blocks

How to use WorldEdit with Modded Blocks

Updated on by

Originally posted on

In Minecraft with tags Forge, Tutorial, WorldEdit

756 words, 3 minutes to read

Using WorldEdit with modded blocks on Minecraft versions before 1.13, such as 1.8.8 or 1.12.2, can be confusing. The ID you see in the inventory rarely works, and you can't use the block's name. Because Minecraft Forge treats items and blocks as separate things, the ID shown in the inventory is often the item’s ID rather than the block’s ID. This means the ID from the inventory may not work directly in WorldEdit, which requires blocks. While this adds extra complexity, there are a few different ways to set blocks from mods easily.

On modern versions of Minecraft, blocks now use namespaced IDs such as minecraft:grass_block, replacing the old numerical ID system used before Minecraft 1.13. This system makes it much easier to use modded blocks with WorldEdit. On older versions, finding the correct block ID can therefore take a little more effort. However, some blocks in 1.13+ may still require these methods if they store additional data or behave in unusual ways. The clipboard pattern detailed below is still especially relevant in newer versions of Minecraft.

Using the Info Tool

The simplest way to find the block ID of a modded block is to use WorldEdit's info tool.

To use the info tool, do the following:

  1. Place or find the block you want to set
  2. Hold any item in your hand (not a block)
  3. Run the /tool info command (or just /tool in some even older versions), turning the item in your hand into the “Info Tool”
  4. Right-click the block you want to find the ID of while holding the item
  5. The chat will show a message that has both the #id and [data] values
    • If it says #429 and [3], such as in the image below, the block's ID is 429:3
  6. Use that ID in the WorldEdit command (eg, //set 429:3)
Using the /info tool
Using the /info tool
Image transcript / description

Visible text

Cherry Wood
Forestry
Axe
-22, 72, 277
N
W  E
S
@(-19.0, 73.0, 279.0): #429 (Unknown) [3] (0/0)
@(-19.0, 73.0, 279.0): #429 (Unknown) [3] (0/0)

Description

First-person Minecraft view aimed at the trunk of a reddish-brown tree under a dense canopy of purple-red leaves. At the top center, an on-screen info overlay identifies the targeted block as “Cherry Wood,” with “Forestry” beneath it and a green checkmark next to “Axe,” indicating the correct tool. In the lower-left chat/overlay area, two identical lines report coordinates and an ID readout: “#429 (Unknown) [3] (0/0).” A square minimap with compass letters (N, W, E, S) sits in the top-right corner with coordinates shown nearby, and the hotbar at the bottom shows a white feather selected while the player’s hand holds the feather on the right.

Using the clipboard pattern

Sometimes modded blocks have extra data, often referred to as “NBT data,” that are required for them to show up correctly. If you’ve seen people refer to a block as “using NBT” or “requiring NBT,” this is likely what they are referring to. In these cases, the block ID by itself isn’t enough. Fortunately, the clipboard pattern can copy all available block data, allowing you to use those blocks correctly with WorldEdit.

WorldEdit accepts #clipboard in place of a block ID, allowing you to //copy something and then use that copied block in other WorldEdit commands. While originally intended for setting intricate patterns or structures, this system also works to set modded blocks containing extra NBT data. The steps to do this are as follows:

  1. Select the block using the selection wand, or //pos1 & //pos2 commands
  2. Run //copy to copy the block into the clipboard
  3. Run any WorldEdit command, using #clipboard as the block ID, eg //set #clipboard
Using the clipboard pattern
Using the clipboard pattern
Image transcript / description

Visible text

Cherry Wood
Forestry
Axe
N
W  E
S
-10, 72, 280
Commands
MineTogether
Operation completed (16 blocks affected).
//set #clipboard

Description

Minecraft first-person view in a grassy forest clearing. In the center is a low 4×4 platform of cherry wood logs placed in a neat grid; the top faces show pale yellow rings bordered by red, and the sides are dark reddish-brown bark. A small white crosshair points at the near edge of the platform, and the player’s hand holds a brown tool or item at the right. UI overlays include a minimap with compass letters and coordinates in the top-right, a vertical menu on the right reading “Commands” and “MineTogether,” and a purple chat/status message at the bottom saying the operation affected 16 blocks, with the command “//set #clipboard” typed below.

This method can also be used to copy the contents of blocks with inventories, or other blocks that store stateful data like that. This makes it a useful trick to remember whether you’re playing modded or not, and it’s still relevant in modern versions of Minecraft.

Using the hand pattern

Finally, most simple blocks can also be used with WorldEdit directly from the inventory. WorldEdit accepts hand in place of a block ID and automatically uses the block associated with the item you’re currently holding. This means you can hold a block in your hand, and type //set hand to set all the blocks in the selected region to the block you’re holding. This works with practically all WorldEdit commands that accept block IDs.

Using the hand pattern
Using the hand pattern
Image transcript / description

Visible text

Cherry Wood
Forestry
Axe
Commands
MineTogether
Operation completed (9 blocks affected).
//set hand _
N
W
E
S
-31, 70, 279

Description

Minecraft first-person view in a grassy forest clearing. In the center foreground, nine cherry wood log blocks are arranged in a flat 3×3 rectangle on the ground, showing pale yellow end-grain squares bordered by dark red bark. The crosshair points at the side of the log structure, and the player appears to be holding another cherry log block in the lower right. At the top center, a tooltip identifies the targeted block as “Cherry Wood” from the Forestry mod, and a purple chat/status line at the bottom says “Operation completed (9 blocks affected).” A minimap with compass directions and coordinates is visible in the top right, and a vertical overlay on the right reads “Commands” and “MineTogether.”

However, this does require the mod that the block is from to correctly set up the item. If WorldEdit cannot determine a valid block from the held item, it will display the message “You’re not holding a block!” If this does happen, the other two methods outlined on this page should still work for you, as they use the actual block itself rather than the item.

A note on hybrid servers

If you’re using a hybrid server, such as one that lets you run both Forge mods and Bukkit plugins at the same time, there are a few extra things to be aware of. Most importantly, you need to make sure to install both the WorldEdit mod and plugin. While you can get away with just the mod in some circumstances, any other plugins that depend on WorldEdit won’t work without the WorldEdit plugin. The WorldEdit plugin by itself, however, will not have access to any blocks added by mods due to limitations in Bukkit. Hybrid servers can often also cause other issues, and are generally not recommended when avoidable.

About the Author
Maddy Miller

Hi, I'm Maddy, a Senior Software Engineer at Microsoft. I write articles and develop Minecraft mods including WorldEdit, WorldGuard, and CraftBook.

I've been in the Minecraft modding and server communities for over 15 years, and love sharing my learnings and experiences with others.

My opinions are my own and do not represent those of my employer.