mirror of
https://github.com/GTNewHorizons/CodeChickenCore.git
synced 2026-11-16 10:04:43 +00:00
Add intersects method to Rectangle4i
Added compare methods to MathHelper
This commit is contained in:
1 parent
699221214c
commit
8a777b265e
2 files changed
+16
No files matched your search
@@ -39,4 +39,10 @@ public class Rectangle4i
|
||||
{
|
||||
return x <= px && px < x+w && y <= py && py < y+h;
|
||||
}
|
||||
|
||||
public boolean intersects(Rectangle4i r)
|
||||
{
|
||||
return x <= r.x+r.w && r.x <= x+w &&
|
||||
y <= r.y+r.h && r.y <= y+h;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user