Porting focus based features and fix rendering

This commit is contained in:
Krzosa Karol
2024-07-26 22:27:36 +02:00
parent 9d02d5ab78
commit 8117d043aa
8 changed files with 134 additions and 70 deletions

View File

@@ -181,3 +181,8 @@ float SafeDivide(float a, float b) {
}
return a / b;
}
bool CheckCollisionPointRec(Vec2 point, Rect2 rec) {
bool result = (point.x >= rec.min.x) && (point.x < rec.max.x) && (point.y >= rec.min.y) && (point.y < rec.max.y);
return result;
}

View File

@@ -141,3 +141,8 @@ Int SafeDivide(Int a, Int b) {
}
return a / b;
}
bool CheckCollisionPointRec(Vec2I point, Rect2I rec) {
bool result = (point.x >= rec.min.x) && (point.x < rec.max.x) && (point.y >= rec.min.y) && (point.y < rec.max.y);
return result;
}