Skip to content

Add Mapblock meta #16125

@kromka-chleba

Description

@kromka-chleba

Problem

Modders may want to store and track some data related to mapblocks in order to for example modify specific mapblocks especially with connection to the newly emerging block callbacks #15999
Currently the only way to do that is to keep that data in mod storage with hashed mapblock pos as the key.
There's a chance this way of storing data is not efficient.

Solutions

Introduce mapblock meta which would allow to store key-value pairs for mapblocks, similarly to node meta, etc.
Different functions would then help to search through the database or find mapblocks with specific information.

Alternatives

Leave it up to modders to reinvent the wheel which I'm already doing anyway.

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions