Skip to content

Structure#place - add option for strict placement #12381

@ShaneBeee

Description

@ShaneBeee

Is your feature request related to a problem?

Not really. Just new API that would be nice.
I guess if I were to think of a problem, when I place structures, block updates happen when I may not want them to.
A good example is flowing water, waterlogging (weird bug in MC), fences updates, etc.

Describe the solution you'd like.

Minecraft 1.21.5 added a new feature for "strict" placement of structures using the structure block and /place template command.
Strict placement allows for the structure to be placed without block updates, ex: water not flowing.

Looking into how the command/structure block do it, it would be as easy as changing this line:

this.structure.placeInWorld(access, blockPosition, blockPosition, definedstructureinfo, randomSource, 2);

changing the flags from 2 to 2 | (strict ? 816 : 0) and adding in a method parameter for strict
For reference the 816 flag is UPDATE_SKIP_ALL_SIDEEFFECTS

Describe alternatives you've considered.

Nothing I can think of!

Other

Visual Example:

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: acceptedDisputed bug is accepted as valid or Feature accepted as desired to be added.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions