Fix Rect3i::contains(rect), it was off by one on the upper sides
This commit is contained in:
parent
41990a47dc
commit
63f207b5d5
@ -6,7 +6,6 @@
|
||||
|
||||
// TODO Could be renamed to something more sensical, like Box3i
|
||||
class Rect3i {
|
||||
|
||||
public:
|
||||
Vector3i pos;
|
||||
Vector3i size;
|
||||
@ -67,9 +66,9 @@ public:
|
||||
return other.pos.x >= pos.x &&
|
||||
other.pos.y >= pos.y &&
|
||||
other.pos.z >= pos.z &&
|
||||
other_end.x < end.x &&
|
||||
other_end.y < end.y &&
|
||||
other_end.z < end.z;
|
||||
other_end.x <= end.x &&
|
||||
other_end.y <= end.y &&
|
||||
other_end.z <= end.z;
|
||||
}
|
||||
|
||||
String to_string() const {
|
||||
|
Loading…
x
Reference in New Issue
Block a user