EngineHub / EngineHub/WorldEdit

Add a way to manipulate nbt of blocks in selection

Open
#2,733 3 comments 1 reaction 0 assignees View on GitHub
status:accepted type:feature-request
Dominant language
Java
Stars
3.5k
Forks
960
Avg merge
6h 57m
Merged PRs (30d)
1

Description

### The Problem

It is extremely tiresome to use worldedit to set LootTables for chests in an area, without destroying their other NBT data.
Or to fix up decorated pot patterns without touching their content.
Or to basically do any non-destructive nbt operation

### A Solution

Add a command/commands to basically mass execute /data merge block {nbt], /data set block {nbt} and /data modify block ...

e.g.:
`//nbtmerge chest {LootTable:"chests/simple_dungeon"}`
`//nbtset {}`
`//nbtmodify decorated_pot shards[0] set "minecraft:skull_pottery_sherd"`

Maybe warn players that bad NBT may crash the game, especially with modded blocks when first using the command.

### Alternatives

Alternatively just allow arbitrary commands to be executed for blocks in selection matching mask.

//execute [mask] command [arguments] §x §y §z [arguments]

Pro:
- more versatile

Con:
- less readable/intuitive commands

### Anything Else?

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.