First cut of some steps for another GLBASIC-HTML5 newbie like myself... what do you think? Anything to add or amend ?
GLBASIC v16 (Steam edition) - Getting started with the HTML Compiler (Windows 10)
Pre-requisites: GLBASIC v16 Steam Edition
1. Purchase the HTML Compiler from Steam as GLBASIC DLC. Once purchased, the HTML Compiler should automatically install via Steam.
There isn't an obvious change to GLBASIC when you launch it, but under Project->Options on the menu, HTML5 and HTML5-webGL options should be available.
2. Install Python. This is not mandatory for the compiler to work, but is needed if you want to test your compiled html5 program in the simplest way. You can install the latest version of Python from the Microsoft App Store.
3. Create a new project with the following code:
SETLOOPSUB "MainLoop1"
SUB MainLoop1:
PRINT "Hello World",10,10
SHOWSCREEN
ENDSUB
The key thing is a SETLOOPSUB should be used for main loops when compiling to HTML5.
4. On the menu go to Project->Options and set Platform Configuration to 'HTML5-WebGL' and click OK.
5. Go to Compile->Build Multiplatform. Click on HTML5-WebGL to compile your project.
6. Locate your project folder in your GLBasic home folder. Navigate to the ..\<projectName>.app sub-folder of your project. If there isn't a Media folder, create one. Inside your Media folder, if you do not have any files, create a simple dummy text file. It doesn't matter what it is called, as long as a file exists here.
7. Go to Compile->Build Multiplatform. Click on HTML5-WebGL to re-compile your project
8. Navigate to the ..\distribute\HTML5 folder and you should see several files of these types: .data, .html, .js, .wasm and .bat. Providing you have installed Python in step 2, you should be able to click on the run_local_test.bat file to run your project in a browser using a local web server.