mirror of
https://github.com/italicsjenga/agb.git
synced 2024-12-23 16:21:33 +11:00
Fix clippy lints for hat-chooses-wizard
This commit is contained in:
parent
48f89edc8c
commit
106ad5fed5
|
@ -174,14 +174,14 @@ mod tiled_export {
|
|||
|
||||
pub const fn get_level() -> Level {{
|
||||
Level {{
|
||||
background: &TILEMAP,
|
||||
foreground: &BACKGROUND,
|
||||
background: TILEMAP,
|
||||
foreground: BACKGROUND,
|
||||
dimensions: Vector2D {{x: WIDTH, y: HEIGHT}},
|
||||
collision: &crate::map_tiles::tilemap::TILE_DATA,
|
||||
collision: crate::map_tiles::tilemap::TILE_DATA,
|
||||
|
||||
enemy_stops: &ENEMY_STOPS,
|
||||
slimes: &SLIMES,
|
||||
snails: &SNAILS,
|
||||
enemy_stops: ENEMY_STOPS,
|
||||
slimes: SLIMES,
|
||||
snails: SNAILS,
|
||||
start_pos: START_POS,
|
||||
}}
|
||||
}}
|
||||
|
|
|
@ -19,7 +19,7 @@ pub struct Level {
|
|||
}
|
||||
|
||||
mod object_tiles {
|
||||
pub const WIZARD_TILE_START: u16 = 0 * 4;
|
||||
pub const WIZARD_TILE_START: u16 = 0;
|
||||
pub const WIZARD_JUMP: u16 = 4 * 4;
|
||||
pub const WIZARD_FALL_START: u16 = 5 * 4;
|
||||
|
||||
|
@ -504,7 +504,7 @@ impl<'a> Player<'a> {
|
|||
let hat_base_tile = match self.num_recalls {
|
||||
0 => object_tiles::HAT_TILE_START,
|
||||
1 => object_tiles::HAT_TILE_START_SECOND,
|
||||
2 | _ => object_tiles::HAT_TILE_START_THIRD,
|
||||
_ => object_tiles::HAT_TILE_START_THIRD,
|
||||
};
|
||||
|
||||
match self.facing {
|
||||
|
@ -540,7 +540,7 @@ impl<'a> Player<'a> {
|
|||
let hat_sprite_divider = match self.num_recalls {
|
||||
0 => 1,
|
||||
1 => 2,
|
||||
2 | _ => 4,
|
||||
_ => 4,
|
||||
};
|
||||
|
||||
let hat_sprite_offset = timer / hat_sprite_divider % 10;
|
||||
|
|
Loading…
Reference in a new issue