From c763d1427ba8672ecac6d6df41bffafb40f9ca53 Mon Sep 17 00:00:00 2001 From: Dan Barber Date: Fri, 9 May 2014 17:57:48 +0100 Subject: [PATCH] Reduce bullet pool to 3. Tweak bullet start position. --- javascripts/game.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/javascripts/game.js b/javascripts/game.js index c046f04..7bd73f4 100644 --- a/javascripts/game.js +++ b/javascripts/game.js @@ -24,7 +24,7 @@ function create () { bullets = game.add.group(); bullets.enableBody = true; bullets.physicsBodyType = Phaser.Physics.ARCADE; - bullets.createMultiple(5, 'bullet'); + bullets.createMultiple(3, 'bullet'); bullets.setAll('anchor.x', 0.5); bullets.setAll('anchor.y', 1); bullets.setAll('checkWorldBounds', true); @@ -81,7 +81,7 @@ function fireBullet () { if (bullet) { // And fire it - bullet.reset(player.x, player.y + 8); + bullet.reset(player.x, player.y - 16); bullet.body.velocity.y = -400; bullet.body.velocity.x = player.body.velocity.x / 4 bulletTime = game.time.now + 500;