Watch
2
0
Fork
You've already forked raylib-cs
0

Sizing and position

Added a few sizing utils to "Rectangle"
Added "GetScreenCenter" to "Raylib.Utils"
This commit is contained in:
Matorio 2025-08-17 00:35:38 -05:00
commit ef5519b8f7
2 changed files with 47 additions and 0 deletions

View file

@ -1561,4 +1561,12 @@ public static unsafe partial class Raylib
UnloadFileText(data);
return text;
}
public static Vector2 GetScreenCenter()
{
Vector2 center = new Vector2();
center.X = GetScreenWidth() / 2.0f;
center.Y = GetScreenHeight() / 2.0f;
return center;
}
}