Skip to content

Commit

Permalink
Reformatted
Browse files Browse the repository at this point in the history
  • Loading branch information
gentlegiantJGC committed Sep 19, 2024
1 parent 37a1c3e commit b91d3a6
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/amulet/resource_pack/abc/resource_pack_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,15 @@ def get_block_model(self, block_stack: BlockStack) -> BlockMesh:
The block should already be in the resource pack format"""
if block_stack not in self._cached_models:
if len(block_stack) == 1:
self._cached_models[block_stack] = self._get_model(block_stack.base_block)
self._cached_models[block_stack] = self._get_model(
block_stack.base_block
)
else:
self._cached_models[block_stack] = BlockMesh.merge(
(self._get_model(block_stack.base_block),)
+ tuple(self._get_model(block_) for block_ in block_stack.extra_blocks)
+ tuple(
self._get_model(block_) for block_ in block_stack.extra_blocks
)
)

return copy.deepcopy(self._cached_models[block_stack])
Expand Down

0 comments on commit b91d3a6

Please sign in to comment.