Datapacks and modifications use the “resource location”/“resource name”/“resource identifier”/“namespaced identifier” system to identify objects. This system *mostly* prevents collisions between named objects. Minecraft discourages creating collisions by recommending unique names, and discourages the use of the minecraft domain. However, minecraft does still check custom entries in this domain. To better optimize code, I recommend that when a datapack defines an entry in the minecraft domain, the behavior is undefined unless:
- The entry is a tag entry, it is not replacing the tag definition, and it is one of the predefined tags.
- The entry is a loot table entry, and it is one of the predefined loot tables
As a result of violating these rules, Minecraft should be free from respecting the behavior of the datapack. This would allow certain optimizations:
1. Minecraft can assume that all items/blocks/entities tagged with a particular predefined tag are always tagged with that tag while the vanilla datapack is loaded.
2. Minecraft can assume that only standard names appear in the “minecraft” domain, and therefore only allow standard names to appear w/o a domain prefix in commands.
3. Minecraft can assume that vanilla structures are not replaced. (Note that this is already the case as far as I can tell.)
0 Comments
Please sign in to leave a comment.
Post a new comment: