Skip to content

Toggling fullscreen #20

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion eepers.adb
Original file line number Diff line number Diff line change
Expand Up @@ -1503,6 +1503,10 @@ begin
end if;
end if;

if Is_Key_Pressed(KEY_F11) or (Is_Key_Down(KEY_LEFT_ALT) and Is_Key_Pressed(KEY_ENTER)) then
Toggle_Fullscreen;
end if;

Any_Key_Pressed := False;
while not Any_Key_Pressed and then Get_Key_Pressed /= KEY_NULL loop
Any_Key_Pressed := True;
Expand Down Expand Up @@ -1653,7 +1657,6 @@ end;
-- TODO: Mother should require several attacks before being "split"
-- TODO: Enemies should attack on zero just like a bomb.
-- TODO: Properly disablable DEV features
-- TODO: Fullscreen mode
-- TODO: Try MSAA (if too slow, don't)
-- TODO: Show Eeper Cooldown timer outside of the screen somehow
-- TODO: Visual Clue that the Eeper is about to kill the Player when Completely outside of the Screen
Expand Down
10 changes: 9 additions & 1 deletion raylib.ads
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ package Raylib is
Import => True,
Convention => C,
External_Name => "CloseWindow";
procedure Toggle_Fullscreen
with
Import => True,
Convention => C,
External_Name => "ToggleFullscreen";

function Window_Should_Close return C_Bool
with
Import => True,
Expand Down Expand Up @@ -77,9 +83,11 @@ package Raylib is
KEY_UP: constant int := 265;
KEY_SPACE: constant int := 32;
KEY_ESCAPE: constant int := 256;
KEY_ENTER: constant Int := 257;
KEY_F11: constant Int := 300;
KEY_ENTER: constant Int := 257;
KEY_LEFT_SHIFT: constant Int := 340;
KEY_RIGHT_SHIFT: constant Int := 344;
KEY_LEFT_ALT: constant Int := 342;

function Is_Key_Pressed(key: int) return C_bool
with
Expand Down