From b4e83e63d46fdbc40f548bfa9bd95d7ed9912b8d Mon Sep 17 00:00:00 2001 From: tom barrett Date: Sat, 13 Jul 2019 04:33:07 -0500 Subject: fmt --- src/tileset.rs | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'src/tileset.rs') diff --git a/src/tileset.rs b/src/tileset.rs index effba3b..fe2f84b 100644 --- a/src/tileset.rs +++ b/src/tileset.rs @@ -95,9 +95,7 @@ impl Tileset { let first_tile = self .tiles .iter() - .find( - |(id, _)| id == &&tile_id - ) + .find(|(id, _)| id == &&tile_id) .unwrap() .1 .clone(); @@ -109,11 +107,14 @@ impl Tileset { .cloned() .filter(|t| { t.properties.entity == first_tile.properties.entity - && (t.properties.rotation - first_tile.properties.rotation) < constants::FLOAT_PRECISION - && t.source.x.is_sign_positive() == first_tile.source.x.is_sign_positive() - && t.source.y.is_sign_positive() == first_tile.source.y.is_sign_positive() + && (t.properties.rotation - first_tile.properties.rotation) + < constants::FLOAT_PRECISION + && t.source.x.is_sign_positive() + == first_tile.source.x.is_sign_positive() + && t.source.y.is_sign_positive() + == first_tile.source.y.is_sign_positive() }) - .collect() + .collect(), ) } else { Animation::new(vec![first_tile]) -- cgit v1.2.3