WorldEdit for Bukkit

WorldEdit for Bukkit

21M Downloads

Adjacency Masks

Owehttamy opened this issue · 2 comments

commented

The Problem

When trying to do something like detail a long path, I want to have the blocks on the edges be a different block. For example, I want a dirt path, but to prevent grass from spreading on it, I need to have coarse dirt between the grass and the dirt.

Example image:

Example

The problem is that there's no simple way to select or mask areas based on what blocks are adjacent to them. Therefore, I cannot mask blocks that are found on the edges of the "pathway", as there isn't any method to determine what the edge even is.

A Solution

We already have offset masks to overlay (>) or underlay (<) blocks amongst one another, as well as expression masks, so I can't imagine it being that difficult to implement a new "adjacency" mask.

Example:

/gmask ~grass_block
//replace dirt coarse_dirt

or something along those lines. I feel like this could be incredibly useful feature and wouldn't be too hard to implement, either!

Alternatives

Supposedly, you're already able to do this with expression masks by using =queryRel(), however I simply cannot figure out how to correctly utilize it—if possible—with the given documentation. So, while I think it would be the most convenient to add support for adjacency masks, simply providing more detail or examples in the expression mask's EngineHub documentation would still go a long way.

Anything Else?

No response

commented
commented

#2056

Ah, sorry for the duplicate. Didn't see this one. I'll close the issue :p