--- a/rust/lib-hwengine-future/src/lib.rs Wed Jan 04 15:26:30 2023 +0100
+++ b/rust/lib-hwengine-future/src/lib.rs Mon Jan 30 15:50:14 2023 +0100
@@ -110,8 +110,8 @@
}
#[no_mangle]
-pub extern "C" fn land_get(game_field: &mut GameField, x: i32, y: i32) -> u16 {
- game_field.collision.map(y, x, |p| *p)
+pub extern "C" fn land_get(game_field: &GameField, x: i32, y: i32) -> u16 {
+ game_field.collision.get(y, x)
}
#[no_mangle]
@@ -138,8 +138,8 @@
}
#[no_mangle]
-pub extern "C" fn land_pixel_get(game_field: &mut GameField, x: i32, y: i32) -> u32 {
- game_field.pixels.map(y, x, |p| *p)
+pub extern "C" fn land_pixel_get(game_field: &GameField, x: i32, y: i32) -> u32 {
+ game_field.pixels.get(y, x)
}
#[no_mangle]