aboutsummaryrefslogtreecommitdiff
path: root/codegen/lib/code/shapes.py
diff options
context:
space:
mode:
Diffstat (limited to 'codegen/lib/code/shapes.py')
-rw-r--r--codegen/lib/code/shapes.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/codegen/lib/code/shapes.py b/codegen/lib/code/shapes.py
index 5d5f826d..0896bd82 100644
--- a/codegen/lib/code/shapes.py
+++ b/codegen/lib/code/shapes.py
@@ -151,18 +151,18 @@ pub trait BlockWithShape {{
impl BlockWithShape for BlockState {{
fn collision_shape(&self) -> &'static VoxelShape {{
- COLLISION_SHAPES_MAP.get(self.id as usize).unwrap_or(&&SHAPE1)
+ COLLISION_SHAPES_MAP.get(self.id() as usize).unwrap_or(&&SHAPE1)
}}
fn outline_shape(&self) -> &'static VoxelShape {{
- OUTLINE_SHAPES_MAP.get(self.id as usize).unwrap_or(&&SHAPE1)
+ OUTLINE_SHAPES_MAP.get(self.id() as usize).unwrap_or(&&SHAPE1)
}}
fn is_collision_shape_empty(&self) -> bool {{
- matches!(self.id, {empty_shape_match_code})
+ matches!(self.id(), {empty_shape_match_code})
}}
fn is_collision_shape_full(&self) -> bool {{
- matches!(self.id, {block_shape_match_code})
+ matches!(self.id(), {block_shape_match_code})
}}
}}