We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 751d3eb + cf7af33 commit ab179ebCopy full SHA for ab179eb
1 file changed
gridkit-rs/src/tile.rs
@@ -207,10 +207,12 @@ impl TileTraits for Tile {
207
}
208
209
fn intersects(&self, other: &Tile) -> bool {
210
- return !(self.start_id.0 >= (other.start_id.0 + other.nx as i64)
+ return !(
211
+ self.start_id.0 >= (other.start_id.0 + other.nx as i64)
212
|| (self.start_id.0 + self.nx as i64) <= other.start_id.0
- || self.start_id.1 >= (other.start_id.1 + other.ny as i64)
213
- || (self.start_id.1 + other.ny as i64) <= other.start_id.1);
+ || self.start_id.1 >= (other.start_id.1 + other.ny as i64)
214
+ || (self.start_id.1 + self.ny as i64) <= other.start_id.1
215
+ );
216
217
218
fn overlap(&self, other: &Tile) -> Result<Tile, String> {
0 commit comments