x4 is absent, so there's surely an error
Adjacent squares don't intersect, so
< should be <=
> should be >=
You didn't indicate whether lower "y" values are located higher (that's what you used) or lower (cartesian), so I can't verify the if you are comparing the "y"s properly.
In reply to Re^3: Checking if squares intersect
by ikegami
in thread Checking if squares intersect
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |