cargo clippy --fix

This commit is contained in:
GBA bot 2022-01-01 12:13:07 +00:00
parent acb6f468e6
commit 5a72c0c0fa
2 changed files with 3 additions and 3 deletions

View file

@ -74,7 +74,7 @@ fn extract_tiles<'a>(layer: &'a tiled::LayerData) -> impl Iterator<Item = u16> +
} }
_ => unimplemented!("cannot use infinite layer"), _ => unimplemented!("cannot use infinite layer"),
} }
.map(|tileid| get_map_id(tileid)) .map(get_map_id)
} }
fn get_map_id(tileid: u32) -> u16 { fn get_map_id(tileid: u32) -> u16 {
@ -103,5 +103,5 @@ fn get_spawn_locations<'a>(
let xs = spawns.iter().map(|pos| pos.0).collect::<Vec<_>>(); let xs = spawns.iter().map(|pos| pos.0).collect::<Vec<_>>();
let ys = spawns.iter().map(|pos| pos.1).collect::<Vec<_>>(); let ys = spawns.iter().map(|pos| pos.1).collect::<Vec<_>>();
return (xs.into_iter(), ys.into_iter()); (xs.into_iter(), ys.into_iter())
} }

View file

@ -1406,7 +1406,7 @@ impl ParticleData {
entity.sprite.set_tile_id((70 + *frame / 3) * 4); entity.sprite.set_tile_id((70 + *frame / 3) * 4);
*frame += 1; *frame += 1;
return UpdateInstruction::None; UpdateInstruction::None
} }
ParticleData::Health(frame) => { ParticleData::Health(frame) => {
if *frame > 8 * 3 * 6 { if *frame > 8 * 3 * 6 {