From 2c12b43b5e4af5d14626a001d01abe5bc477fb45 Mon Sep 17 00:00:00 2001 From: neingeist Date: Sun, 24 Nov 2013 21:38:03 +0100 Subject: [PATCH] add background to game --- platformer.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/platformer.js b/platformer.js index c6f4783..2d2876b 100644 --- a/platformer.js +++ b/platformer.js @@ -132,7 +132,7 @@ Q.Sprite.extend("Starbug",{ Q.scene("level1",function(stage) { // Add in a repeater for a little parallax action - stage.insert(new Q.Repeater({ asset: "background-wall.png", speedX: 0.5, speedY: 0.5 })); + stage.insert(new Q.Repeater({ asset: "background.png", speedX: 0.5, speedY: 0.5 })); // Add in a tile layer, and make it the collision layer stage.collisionLayer(new Q.TileLayer({ @@ -183,7 +183,7 @@ Q.scene('endGame',function(stage) { // Q.load can be called at any time to load additional assets // assets that are already loaded will be skipped // The callback will be triggered when everything is loaded -Q.load("sprites.png, sprites.json, level.json, tiles.png, background-wall.png", function() { +Q.load("sprites.png, sprites.json, level.json, tiles.png, background.png", function() { // Sprites sheets can be created manually Q.sheet("tiles","tiles.png", { tilew: 32, tileh: 32 });