During gameplay, the display fits the entire viewport nicely:
- Gameplay: http://i.imgur.com/fgJjmGc.png
But the title is off to the left:
- Title Screen: http://i.imgur.com/uOZpNyY.png
I understand this is due to the loaded background image of the title screen, but at centering it on the black background would look nicer.
Game.js: video loader:
if (!me.video.init(800, 600, {
wrapper : "screen",
renderer : me.video.CANVAS,
scale : "auto",
scaleMethod : "flex-width",
doubleBuffering : true,
transparent : true,
antiAlias : true
})) {
alert("Your browser does not support HTML5 canvas.");
return;
}
Title.js (Title screen):
me.game.world.addChild(new (me.Renderable.extend ({
// constructor
init : function() {
this._super(me.Renderable, 'init', [0, 0, me.game.viewport.width, me.game.viewport.height]);
this._super(me.Renderable, 'init', [(me.game.viewport.width - 800) / 2,(me.game.viewport.height - 600) / 2,800,600]);
--
You received this message because you are subscribed to the Google Groups "melonJS - A lightweight HTML5 game engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to melonjs+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
To unsubscribe from this group and stop receiving emails from it, send an email to melonjs+unsubscribe@googlegroups.com.