wade.setLoadingBar(true, 1,140);
Seth

Hello, this should be an easy thing to do, but I am having trouble with it. I am trying to set the position of the loading bar in app.js. Here is my code:

App = function()
{
    // this is where the WADE app is initialized
	this.init = function()
	{
	    wade.setLoadingImages('loading_blk.jpg');
	    
	    wade.setLoadingBar(true, 1,140);

        // load a scene
		wade.loadScene('menu.wsc', true, function()
        {
            // the scene has been loaded, do something here

        });
	};
};

The documentation says: {Object} position Optional

An object with x and y fields describing the position in pixels (relative to the screen center) where the loading bar should appear. This is only relevant if the visible parameter is true.

Can anyone tell me what I am doing wrong? Thanks!

All 3 Comments
Gio

What the documentation means is that you need to use an object rather than passing two numbers:

wade.setLoadingBar(true, {x: 1, y: 140});

By the way I had a quick look at your game yesterady, looks really nice with a lot of content, keep it up.

Seth

Thanks Gio! I couldn't have done it without you. Speaking of which, where can I find the powered by wade graphic to display on the splash screen and credits? Preferably a dark one.

Gio

Hi

I've attached the one that we've used on our own games, I hope it works for the layout of yours?

Thanks, we do appreciate you adding the logo to your game.

Post a reply
Add Attachment
Submit Reply
Login to Reply