HTML5 Full Screen Extension

Add to
My games
Add to
Wishlist
Save to
Collection
No reviews
Exceptional
Meh
Skip

About

Demo instructions: run it and move the character. You'll see a grey "Fullscreen button" on the bottom right. Click it to enter full screen. While on fullscreen, click on the button again to exit back to windowed mode.

As you probably know, window_set_fullscreen() does not work on HTML5. So  after searching online, I basically copy/pasted a small Javascript code for a GMS1 extension found in this forum post (full credit to the original author),  in order to create a button that is added on top of the game canvas (I chose the bottom right corner but you can change that on the provided script), that lets you toggle full screen on or off.  Check out the demo "game" above.

By the way, the itch.io option to include a fullscreen button makes the browser full screen but does not actually scale the canvas.

I also added a small utility function,  to check whether the game is in full screen that works cross-platform, including HTML5.

I included a button sprite, but obviously you can change that to whatever you want.

Disclaimer

Tested on GameMaker 2022.8+ (uses a  call_later  call) on current versions of Opera GX, Chrome and Edge. Firefox does not seem to work as expected. Provided as is - expect little to no support, hopefully you won't need it :)

I also included the demo GameMaker project if you want/need, on a separate file.

Platforms
Release date
Developer
manta ray
Age rating
Not rated

System requirements for Web

System requirements for PC

Read more...
HTML5 Full Screen Extension screenshot, image №3578025 - RAWG
Edit the game info
Last Modified: Sep 23, 2022

Where to buy

itch.io