Full Screen Game. How?
Monkey Forums/Monkey Programming/Full Screen Game. How?
| ||
Why, when creating an HTML5 game are we restricted to a screen or canvas size of 640 x 480 pixels? How do we adjust the size of the canvas, is it possible? I have scoured the command/language index but to no avail. If this is not achievable through HTML5 compilation how else might I have full screen control as easily accomplished with Blitz Basic/Plus, Blitz Max etc.? I eagerly await your help and solutions, thankyou. :) |
| ||
You need to edit the MonkeyGame.html file inside the .build folder of your project. |
| ||
The diddy module has a SetNativeGraphicsSize function which you may find useful also |
| ||
Whilst I am now able to resize the canvas, which has been a great achievement, I wonder is it possible to remove both web address bar and task bar allowing the use of the entire screen? |
| ||
In firefox, Chrome and Safari you can request full-screen mode in HTML5: https://hacks.mozilla.org/2012/01/using-the-fullscreen-api-in-web-browsers/ |