Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- boolean left = (Math.abs(centerX1 - (width1 / 2)) < Math.abs((centerX2 + (width2 / 2)))) ||
- (Math.abs(centerX1 - (width1 / 2)) == Math.abs((centerX2 + (width2 / 2))));
- boolean right = ((centerX1 + (width1 / 2)) > (centerX2 - (width2 / 2))) ||
- ((centerX1 + (width1 / 2)) == (centerX2 - (width2 / 2)));
- boolean up = ((centerY1 + (length1 / 2)) > (centerY2 - (length2 / 2))) ||
- ((centerY1 + (length1 / 2)) == (centerY2 - (length2 / 2)));
- boolean down = ((centerY1 - (length1 / 2)) < (centerY2 + (length2 / 2))) ||
- ((centerY1 - (length1 / 2)) == (centerY2 + (length2 / 2)));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement