summaryrefslogtreecommitdiff
path: root/game.adb
diff options
context:
space:
mode:
authorrexim <reximkut@gmail.com>2024-03-10 23:07:17 +0700
committerrexim <reximkut@gmail.com>2024-03-10 23:07:17 +0700
commit5a89655e5a6e0d91eb6dcb1968ffc99b5fe0f7c5 (patch)
treec55dc5fa0ced31a4b580d2a1b94e040cd2dc2291 /game.adb
parent8719bb05efc99018735a5ede75c78386fafa0a6a (diff)
Lock FPS to 60
Diffstat (limited to 'game.adb')
-rw-r--r--game.adb2
1 files changed, 2 insertions, 0 deletions
diff --git a/game.adb b/game.adb
index c9c8fb6..d20f166 100644
--- a/game.adb
+++ b/game.adb
@@ -449,6 +449,7 @@ begin
Put_Line("Keys: " & Integer'Image(Game.Player.Keys));
Set_Config_Flags(FLAG_WINDOW_RESIZABLE);
Init_Window(800, 600, Title);
+ Set_Target_FPS(60);
while Window_Should_Close = 0 loop
Begin_Drawing;
Clear_Background(COLOR_BACKGROUND);
@@ -474,6 +475,7 @@ begin
End_Mode2D;
Game_Hud(Game);
+ Draw_FPS(10, 10);
End_Drawing;
end loop;
Close_Window;