Line 40: |
Line 40: |
| * A datapack registry json is loaded that refers to another registrable by id, e.g. "minecraft:desert" | | * A datapack registry json is loaded that refers to another registrable by id, e.g. "minecraft:desert" |
| * A standalone reference holder is retrieved from the relevant registry via a get-or-create operation | | * A standalone reference holder is retrieved from the relevant registry via a get-or-create operation |
− | * When a datapack registry json is loaded and fully parsed, a holder for that json is get-or-created *and* the parsed value is bound to it | + | * When a datapack registry json is loaded and fully parsed, a holder for that json is get-or-created ''and'' the parsed value is bound to it |
| * When registries freeze, the get-or-create operation can no longer create new holders. If any reference holders in the registry are not fully bound at this time (with both a key and a value), an error is raised. This will occur if a datapack registry json refers by id to another datapack registry json that does not exist, and is how these references-by-id are validated. | | * When registries freeze, the get-or-create operation can no longer create new holders. If any reference holders in the registry are not fully bound at this time (with both a key and a value), an error is raised. This will occur if a datapack registry json refers by id to another datapack registry json that does not exist, and is how these references-by-id are validated. |
| * Whenever tags load, each tag file's TagKey is bound to all reference holders referred to in that tag (this modifiers the holders in-place). | | * Whenever tags load, each tag file's TagKey is bound to all reference holders referred to in that tag (this modifiers the holders in-place). |
| | | |
− | When datagenerating datapack registry jsons with reference holders, any reference holders *must* be created by the specific registry instances used by the RegistryOps/RegistryAccess used to datagen the jsons, or they will fail to serialize. | + | When datagenerating datapack registry jsons with reference holders, any reference holders ''must'' be created by the specific registry instances used by the RegistryOps/RegistryAccess used to datagen the jsons, or they will fail to serialize. |
| | | |
| ===== Intrusive Reference Holders ===== | | ===== Intrusive Reference Holders ===== |