So... how do I get rid of that console for html?

Monkey Forums/Monkey Beginners/So... how do I get rid of that console for html?

GarBenjamin(Posted 2015) [#1]
Hey, I apologize if this is something that is actually obvious.

It's not to me.

Just wondering how in heck do I turn off that console at the bottom of HTML apps?

I thought maybe it was something automatically added when the compiler finds a Print statement so I made a very simple test project that only loaded and displayed an image on the screen. Nope. The console still appears at the bottom of the web page.

I am about to start work porting the GLBasic game to Monkey X, Haxe Flixel and Unity and just want to get some tidbits like this sorted out before I begin.

Thanks!


skid(Posted 2015) [#2]
I suggest the following

1 - clone the %monkey%/targets/html5 folder to say %monkey%/targets/web

2 - in targets/web/TARGET.MONKEY file change the TARGET_NAME to something like "Web Game"

3 - replace the targets/web/template/MonkeyGame.html file with the following or similar



Now, when you rerun monkey, you should have a new target which will be same as html5 target but give you one big canvas for your game to run on.

You may then need to fix the size of the canvas in the html page or adopt your OnRender code to dynamically adapt to changes in DeviceWidth and DeviceHeight values.

warning: it can be confusing when changing files in the target directory, typically you need to do a clean build for monkey to resync your project with such changes.


rIKmAN(Posted 2015) [#3]
You can edit the html file to remove it for that program, or edit the template to have it removed in every generated build.


GarBenjamin(Posted 2015) [#4]
Ah okay. Thanks. Yeah, I saw the code in the html for the splitter and the console and thought about editing it all out.

Then thought well heck there is probably some #option to set in the code or editor to do that. ;)

Sounds like there really isn't so editing is no problem. Thanks!


Hotshot(Posted 2015) [#5]
I have click your links to see if you do have email unfortunate you dont have one as I did like talk on 2D Library that You have done :-)


GarBenjamin(Posted 2015) [#6]
@Hotshot:

If you are talking to me probably the best way to get in contact now is through Twitter.
My handle is MrGarBenjamin on there.

Just do a search for @MrGarBenjamin and you should find me. I probably will also show up if you do some searches for #MonkeyX because I have started tweeting (really? are we birds?!) about my current project of converting the GLBasic demo game to MonkeyX.

I will eventually get an email set up on my website and a Contact form as well. Right now I have several projects going on at the same time and only a few hours per day to do them all. So everything is raising slowly.