Skip to content

Commit cdcda1b

Browse files
Fix air rendering (#38)
Fixes Amulet-Team/Amulet-Map-Editor#1119 These two lines of code were to display the missing block if the block had textures but no elements which is the case for polygon mesh formats that we don't support. Minecraft Java 1.21.4 added a particle texture which broke this.
1 parent fe32145 commit cdcda1b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

minecraft_model_reader/api/resource_pack/java/resource_pack_manager.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,9 @@ def _load_block_model(self, model_path: str) -> BlockMesh:
356356
}
357357
transparent = Transparency.Partial
358358

359-
if java_model.get("textures", {}) and not java_model.get("elements"):
359+
if set(java_model.get("textures", {})).difference(
360+
{"particle"}
361+
) and not java_model.get("elements"):
360362
return self.missing_block
361363

362364
for element in java_model.get("elements", {}):

0 commit comments

Comments
 (0)