User prompt
Please fix the bug: 'TypeError: undefined is not an object (evaluating 'enemies[i].intersects')' in or related to this line: 'if (enemies[i].intersects(hero)) {' Line Number: 491
User prompt
Make the opacity of the laser charge a consistent 50%
User prompt
Make the transition between axis stretches faster
User prompt
Compress the laser charge more along the Y axis during the stretch. It should get very thin.
User prompt
Flatten the asset more on the Y axis stretch and when the x axis stretch happens, flatten the Y axis quickly at the same time.
User prompt
Let’s try this for the laser charge. Remove the spin all together. Instead on spawn, flatten and stretch the laser charge asset along the Y axis for one second before flattening and stretching the asset along the X axis.
User prompt
Slow the spin of the laser charge by half
User prompt
Laser charge should start at 50% opacity and spin should start much slower.
User prompt
Create a laser attack sequence for the Blaster enemy: Have Blaster stop moving while charging. Phase 1: Charge-up Phase (2 seconds): - Spawn asset LaserCharge at the center of Blaster at 75% opacity. On spawn it should start growing and getting brighter. Also on spawn the laser charge should start spinning and increase speed as it grows. After charge up is over, destroy laser charge.
User prompt
Have central particle start at a scale of 1
User prompt
Make sure that central particle grows bigger and brighter with every particle that reaches center.
User prompt
1. The `self.chargeParticles` array is never initialized. Let's move it to the start of the class: ```javascript var Blaster = Container.expand(function () { var self = Container.call(this); var blasterGraphics = self.attachAsset('Blaster', { anchorX: 0.5, anchorY: 0.5 }); self.HitPoints = 5; self.speed = 3; self.shootInterval = 60; self.chargeParticles = []; // Initialize here self.isCharging = false; // Add this too self.update = function () { // Rest of the code... ``` 2. Then modify the charging section: ```javascript if (self.isCharging) { var chargeDuration = LK.ticks - self.chargeStartTime; if (chargeDuration < 120) { // 2 seconds charge-up if (!self.centralParticle) { self.centralParticle = LK.getAsset('LaserChargeParticle', { anchorX: 0.5, anchorY: 0.5, x: self.x, y: self.y, scaleX: 2, scaleY: 2, alpha: 1, visible: true }); game.addChild(self.centralParticle); game.setChildIndex(self.centralParticle, game.children.length - 1); } // Update central particle position if (self.centralParticle) { self.centralParticle.x = self.x; // Add this to keep central particle with enemy self.centralParticle.y = self.y; self.centralParticle.scaleX += 0.02; self.centralParticle.scaleY += 0.02; self.centralParticle.alpha = Math.min(1, self.centralParticle.alpha + 0.02); } if (chargeDuration % 30 === 0) { // Rest of particle spawn code... } ``` 3. And in the cleanup section: ```javascript } else { // Destroy all laser particles if (self.chargeParticles.length > 0) { // Add check self.chargeParticles.forEach(function (particle) { particle.destroy(); }); self.chargeParticles = []; // Reset array } if (self.centralParticle) { self.centralParticle.destroy(); self.centralParticle = null; // Make sure to null it } self.isCharging = false; }
User prompt
Set central charge particle starting scale to 2
User prompt
Change the conditions of the central charge particle and make sure it is not dependent on other charge particles and is created first
User prompt
Add this change: Try modifying the code like this: ``` if (chargeDuration % 30 === 0) { // Spawn a new particle every 0.5 seconds var angle = chargeDuration / 120 * Math.PI * 2; var particle = LK.getAsset('LaserChargeParticle', { anchorX: 0.5, anchorY: 0.5, x: self.x + Math.cos(angle) * 50, y: self.y + Math.sin(angle) * 50, scaleX: 1, scaleY: 1 }); game.addChild(particle); self.chargeParticles.push(particle); } // Update central particle independently if (self.centralParticle) { self.centralParticle.scaleX += 0.02; self.centralParticle.scaleY += 0.02; self.centralParticle.alpha = Math.min(1, self.centralParticle.alpha + 0.02); } self.chargeParticles.forEach(function (particle, index) { // Move particles towards the center particle.x += (self.x - particle.x) * 0.1; particle.y += (self.y - particle.y) * 0.1; if (Math.abs(particle.x - self.x) < 5 && Math.abs(particle.y - self.y) < 5 && particle !== self.centralParticle) { particle.destroy(); self.chargeParticles.splice(index, 1); } });
User prompt
Make sure central particle visible is true.
User prompt
I think that the code that destroys particles when they reach the center of the charge point is destroying the central particle as soon as it is created. Make sure it does not.
User prompt
Stop spawning drones and bruisers for now
User prompt
Change the charge particle code to recognize a central particle and only increase that particles size and brightness. Central particle does not get destroyed until charge timer is complete.
User prompt
Central particle alpha should be 1
User prompt
Need to make sure central particle is above Blaster layer. It’s not visible currently.
User prompt
I don’t see a central particle appearing on blaster charge up
User prompt
When the first laser charge particle reaches center of Blaster, create a particle at gathering point. This particle should grow in size and brightness with each other particle that reaches it
User prompt
The charge up for blaster is not working right. Let me describe it again sequentially. Blaster stops moving. Particles are spawned one at a time and swirl towards center of Blaster. When the first particle reaches center leave that particle there and increase brightness. Each additional particle that reaches center should be destroyed and the first particle should increase in size and brightness. Continue to do this for 2 seconds and then destroy all particles.
User prompt
After the charge duration is done, destroy all laser particles.
/**** * Classes ****/ // Blaster class representing a shooting enemy var Blaster = Container.expand(function () { var self = Container.call(this); var blasterGraphics = self.attachAsset('Blaster', { anchorX: 0.5, anchorY: 0.5 }); self.HitPoints = 5; // Moderate hit points for Blaster self.speed = 3; // Moderate speed for Blaster self.shootInterval = 60; // Interval for shooting bullets self.chargeParticles = []; // Initialize here self.isCharging = false; // Add this too self.update = function () { // Laser charge-up phase if (LK.ticks % 240 === 0) { // Every 4 seconds self.isCharging = true; self.chargeStartTime = LK.ticks; } if (self.isCharging) { var chargeDuration = LK.ticks - self.chargeStartTime; if (chargeDuration < 120) { // 2 seconds charge-up if (!self.centralParticle) { self.centralParticle = LK.getAsset('LaserChargeParticle', { anchorX: 0.5, anchorY: 0.5, x: self.x, y: self.y, scaleX: 1, scaleY: 1, alpha: 1, visible: true }); game.addChild(self.centralParticle); game.setChildIndex(self.centralParticle, game.children.length - 1); } // Update central particle position if (self.centralParticle) { self.centralParticle.x = self.x; // Add this to keep central particle with enemy self.centralParticle.y = self.y; self.centralParticle.scaleX += 0.02; self.centralParticle.scaleY += 0.02; self.centralParticle.alpha = Math.min(1, self.centralParticle.alpha + 0.02); } if (chargeDuration % 30 === 0) { // Spawn a new particle every 0.5 seconds var angle = chargeDuration / 120 * Math.PI * 2; var particle = LK.getAsset('LaserChargeParticle', { anchorX: 0.5, anchorY: 0.5, x: self.x + Math.cos(angle) * 50, y: self.y + Math.sin(angle) * 50, scaleX: 1, scaleY: 1 }); game.addChild(particle); self.chargeParticles.push(particle); } self.chargeParticles.forEach(function (particle, index) { // Move particles towards the center particle.x += (self.x - particle.x) * 0.1; particle.y += (self.y - particle.y) * 0.1; if (Math.abs(particle.x - self.x) < 5 && Math.abs(particle.y - self.y) < 5 && particle !== self.centralParticle) { particle.destroy(); self.chargeParticles.splice(index, 1); // Increase central particle size and brightness if (self.centralParticle) { self.centralParticle.scaleX += 0.1; self.centralParticle.scaleY += 0.1; self.centralParticle.alpha = Math.min(1, self.centralParticle.alpha + 0.1); } } }); } else { // Destroy all laser particles if (self.chargeParticles.length > 0) { // Add check self.chargeParticles.forEach(function (particle) { particle.destroy(); }); self.chargeParticles = []; // Reset array } if (self.centralParticle) { self.centralParticle.destroy(); self.centralParticle = null; // Make sure to null it } self.isCharging = false; } } else { // Move downwards // Check for nearby enemies and adjust path to avoid collisions var nearbyEnemy = enemies.find(function (enemy) { return enemy !== self && Math.abs(enemy.x - self.x) < 100 && Math.abs(enemy.y - self.y) < 100; }); if (nearbyEnemy) { self.x += (self.x < nearbyEnemy.x ? -1 : 1) * self.speed; // Move away from the nearby enemy } else { self.y += self.speed; } // Shoot bullets at regular intervals if (LK.ticks % self.shootInterval === 0) { var blasterBullet = new BlasterBullet(); blasterBullet.x = self.x; blasterBullet.y = self.y + blasterGraphics.height / 2; game.addChild(blasterBullet); enemies.push(blasterBullet); } } // Destroy if out of screen if (self.y > 2732) { self.destroy(); var index = enemies.indexOf(self); if (index > -1) { enemies.splice(index, 1); } } }; }); // BlasterBullet class for blaster's bullets var BlasterBullet = Container.expand(function () { var self = Container.call(this); var bulletGraphics = self.attachAsset('heroBullet', { anchorX: 0.5, anchorY: 0.5 }); self.speed = 5; // Speed of the bullet self.update = function () { self.y += self.speed; if (self.y > 2732) { self.destroy(); var index = enemies.indexOf(self); if (index > -1) { enemies.splice(index, 1); } } }; }); // Bruiser class representing a tougher enemy var Bruiser = Container.expand(function () { var self = Container.call(this); var bruiserGraphics = self.attachAsset('Bruiser', { anchorX: 0.5, anchorY: 0.5 }); self.HitPoints = 10; // Higher hit points for Bruiser self.speed = 4; // Increased speed for Bruiser self.update = function () { // Implement mechanical stomping movement if (LK.ticks % 80 < 20) { bruiserGraphics.scale.x = 1.1; bruiserGraphics.scale.y = 0.9; bruiserGraphics.rotation = 0.1; // Tilt right } else if (LK.ticks % 80 < 40) { bruiserGraphics.scale.x = 1.0; bruiserGraphics.scale.y = 1.0; bruiserGraphics.rotation = 0; } else if (LK.ticks % 80 < 60) { bruiserGraphics.scale.x = 1.1; bruiserGraphics.scale.y = 0.9; bruiserGraphics.rotation = -0.1; // Tilt left } else { bruiserGraphics.scale.x = 1.0; bruiserGraphics.scale.y = 1.0; bruiserGraphics.rotation = 0; } // Move downwards only during tilt phases if (LK.ticks % 80 < 20 || LK.ticks % 80 >= 40 && LK.ticks % 80 < 60) { // Check for nearby enemies and adjust path to avoid collisions var nearbyEnemy = enemies.find(function (enemy) { return enemy !== self && Math.abs(enemy.x - self.x) < 100 && Math.abs(enemy.y - self.y) < 100; }); if (nearbyEnemy) { self.x += (self.x < nearbyEnemy.x ? -1 : 1) * self.speed; // Move away from the nearby enemy } else { self.y += self.speed; } } if (self.y > 2732) { self.destroy(); var index = enemies.indexOf(self); if (index > -1) { enemies.splice(index, 1); } } }; }); // BruiserPiece class for bruiser destruction effect var BruiserPiece = Container.expand(function (assetType) { var self = Container.call(this); var pieceGraphics = self.attachAsset(assetType, { anchorX: 0.5, anchorY: 0.5 }); self.speedX = -Math.random() * 6 + 3; // Switch direction of horizontal speed self.speedY = Math.random() * 4 - 2; // Random vertical speed self.alphaDecay = 0.02; // Rate at which the piece fades out self.update = function () { self.x += self.speedX; self.y += self.speedY; pieceGraphics.rotation += Math.random() * 0.1 - 0.05; // Add slight random rotation pieceGraphics.alpha -= self.alphaDecay; if (pieceGraphics.alpha <= 0) { self.destroy(); } }; }); // Enemy class representing the enemy robots var Drone = Container.expand(function () { var self = Container.call(this); var droneGraphics = self.attachAsset('Drone', { anchorX: 0.5, anchorY: 0.5 }); self.HitPoints = 3; self.randomOffset = Math.random() * 100; // Random timing for each drone self.speed = 2.25; self.update = function () { // Add robotic hover effects // Check for nearby enemies and adjust path to avoid collisions var nearbyEnemy = enemies.find(function (enemy) { return enemy !== self && Math.abs(enemy.x - self.x) < 100 && Math.abs(enemy.y - self.y) < 100; }); if (nearbyEnemy) { self.x += (self.x < nearbyEnemy.x ? -1 : 1) * self.speed; // Move away from the nearby enemy } else { self.y += self.speed * (Math.random() > 0.1 ? 1 : 0); // Brief pauses in downward movement } self.x += Math.sin(LK.ticks / 10 + self.randomOffset) * 2; // Small jerky side-to-side movements if (Math.random() > 0.95) { self.x += Math.random() * 4 - 2; // Quick position corrections } // Pulse effect on hit if (self.pulseEffect) { droneGraphics.scale.x = 1.2; droneGraphics.scale.y = 1.2; self.pulseEffect = false; } else { droneGraphics.scale.x = 1.0; droneGraphics.scale.y = 1.0; } if (self.y > 2732) { self.destroy(); var index = enemies.indexOf(self); if (index > -1) { enemies.splice(index, 1); } } }; }); // DronePiece class for drone destruction effect var DronePiece = Container.expand(function (assetType) { var self = Container.call(this); var pieceGraphics = self.attachAsset(assetType, { anchorX: 0.5, anchorY: 0.5 }); self.speedX = Math.random() * 6 - 3; // Increased random horizontal speed self.speedY = Math.random() * 4 - 2; // Random vertical speed self.alphaDecay = 0.02; // Rate at which the piece fades out self.update = function () { self.x += self.speedX; self.y += self.speedY; pieceGraphics.rotation += Math.random() * 0.1 - 0.05; // Add slight random rotation pieceGraphics.alpha -= self.alphaDecay; if (pieceGraphics.alpha <= 0) { self.destroy(); } }; }); // Dust class for dust particles var Dust = Container.expand(function () { var self = Container.call(this); var dustGraphics = self.attachAsset('Dust', { anchorX: 0.5, anchorY: 0.5 }); dustGraphics.alpha = 0.75; self.speed = Math.random() * 3 + 1; self.rotationSpeed = Math.random() * 0.02 - 0.01; // Random rotation speed between -0.01 and 0.01 self.direction = Math.random() * Math.PI * 0.5; self.update = function () { self.y += self.speed; self.x += Math.sin(self.direction) * self.speed; // Add slight X travel based on direction self.rotation += self.rotationSpeed; // Add rotation dustGraphics.alpha -= 0.01; // fade out at a medium pace if (self.y > 2732 || dustGraphics.alpha <= 0) { self.destroy(); } }; }); // Assets will be automatically created and loaded by the LK engine based on their usage in the code. // Hero class representing the player's spaceship var Hero = Container.expand(function () { var self = Container.call(this); self.prevX = self.x; // Initialize prevX with the current x position var heroGraphics = self.attachAsset('hero', { anchorX: 0.5, anchorY: 0.5 }); self.speed = 10; self.update = function () { if (self.y > 2375) { self.y -= self.speed; } // Add rotation based on movement direction if (self.x > self.prevX) { self.rotation += Math.PI / 180 * 1; // Rotate 1 degree to the right if (self.rotation > Math.PI / 180 * 5) { self.rotation = Math.PI / 180 * 5; } } else if (self.x < self.prevX) { self.rotation -= Math.PI / 180 * 1; // Rotate 1 degree to the left if (self.rotation < Math.PI / 180 * -5) { self.rotation = Math.PI / 180 * -5; } } else { if (self.rotation > 0) { self.rotation -= Math.PI / 180 * 1; if (self.rotation < 0) { self.rotation = 0; } } else if (self.rotation < 0) { self.rotation += Math.PI / 180 * 1; if (self.rotation > 0) { self.rotation = 0; } } } self.prevX = self.x; // Store the current x position for the next frame // Add scale change to simulate footsteps if (LK.ticks % 24 < 12) { self.scale.x = 1.02; } else { self.scale.x = 0.98; } }; }); // Bullet class for hero's bullets var HeroBullet = Container.expand(function () { var self = Container.call(this); var bulletGraphics = self.attachAsset('heroBullet', { anchorX: 0.5, anchorY: 0.5 }); self.speed = -15; self.Type = 'standard'; // Default type for bullets self.Power = 1; // Default power level for bullets self.update = function () { self.y += self.speed; if (self.y < 0) { self.destroy(); var index = heroBullets.indexOf(self); if (index > -1) { heroBullets.splice(index, 1); } } }; }); // RailingLeft class for the scrolling left railing var RailingLeft = Container.expand(function (assetType) { var self = Container.call(this); var railingGraphics = self.attachAsset(assetType, { anchorX: 0.5, anchorY: 0 }); self.speed = 2; self.update = function () { self.y += self.speed; if (self.y >= 2732) { self.y = -2732; } }; }); // RailingRight class for the scrolling right railing var RailingRight = Container.expand(function (assetType) { var self = Container.call(this); var railingGraphics = self.attachAsset(assetType, { anchorX: 0.5, anchorY: 0 }); self.speed = 2; self.update = function () { self.y += self.speed; if (self.y >= 2732) { self.y = -2732; } }; }); // RoadScroll class for the scrolling road var RoadScroll = Container.expand(function (assetType) { var self = Container.call(this); var roadGraphics = self.attachAsset(assetType, { anchorX: 0.5, anchorY: 0 }); if (assetType === 'CityBackgroundHD') { self.speed = 1; } else { self.speed = 2; } self.update = function () { self.y += self.speed; if (self.y >= 2732) { self.y = -2732; } }; }); // TitleScreen class for the title screen var TitleScreen = Container.expand(function () { var self = Container.call(this); // Attach game logo var logo = self.attachAsset('GameLogoHD', { anchorX: 0.5, anchorY: 0.5 }); logo.x = 2048 / 2; logo.y = 2732 / 2 - 200; // Attach play button var playButton = self.attachAsset('PlayButton', { anchorX: 0.5, anchorY: 0.5 }); playButton.x = 2048 / 2; playButton.y = logo.y + logo.height / 2 + playButton.height / 2 + 50; // Event handler for play button playButton.down = function (x, y, obj) { isTitle = false; isStarted = true; self.destroy(); startGame(); }; }); /**** * Initialize Game ****/ var game = new LK.Game({ backgroundColor: 0x000000 //Init game with black background }); /**** * Game Code ****/ // Initialize the city background for parallax effect var cityBackground1 = game.addChild(new RoadScroll('CityBackgroundHD')); var cityBackground2 = game.addChild(new RoadScroll('CityBackgroundHD')); cityBackground1.x = 2048 / 2; cityBackground2.x = 2048 / 2; cityBackground1.y = 0; cityBackground2.y = -2732; // Initialize the road instances var road1 = game.addChild(new RoadScroll('Road')); var road2 = game.addChild(new RoadScroll('Road2')); road2.x = 2048 / 2; road1.x = 2048 / 2; road1.y = 0; road2.y = -2732; // Initialize the left railing instances var railingLeft1 = game.addChild(new RailingLeft('RailingStart')); var railingLeft2 = game.addChild(new RailingLeft('RailingEnd')); railingLeft1.x = 2048 * 0.16; railingLeft2.x = 2048 * 0.16; railingLeft1.y = 0; railingLeft2.y = -2732; // Initialize the right railing instances var railingRight1 = game.addChild(new RailingRight('RailingEnd')); var railingRight2 = game.addChild(new RailingRight('RailingStart')); railingRight1.x = 2048 * 0.81; // Moved left by 3% railingRight2.x = 2048 * 0.81; // Moved left by 3% railingRight1.y = 0; railingRight2.y = -2732; // Initialize game state variables var isTitle = true; var isStarted = false; // Initialize title screen if (isTitle) { var titleScreen = game.addChild(new TitleScreen()); } // Function to start the game function startGame() { // Initialize hero hero = game.addChild(new Hero()); hero.x = 2048 / 2; hero.y = 2732 + hero.height; // Initialize enemies and bullets arrays enemies = []; heroBullets = []; } // Initialize variables var hero; var enemies = []; var heroBullets = []; // Function to handle game updates game.update = function () { // Update the city background instances for parallax effect cityBackground1.update(); cityBackground2.update(); // Update the road instances road1.update(); road2.update(); // Update the left railing instances railingLeft1.update(); railingLeft2.update(); // Update the right railing instances railingRight1.update(); railingRight2.update(); if (isStarted) { if (dragNode) { hero.x = dragNode.x; hero.y = dragNode.y; } // Update enemies for (var i = enemies.length - 1; i >= 0; i--) { enemies[i].update(); if (enemies[i].intersects(hero)) { LK.effects.flashScreen(0xff0000, 1000); LK.showGameOver(); } } // Update hero bullets for (var j = heroBullets.length - 1; j >= 0; j--) { heroBullets[j].update(); for (var k = enemies.length - 1; k >= 0; k--) { if (heroBullets[j].intersects(enemies[k]) && enemies[k].y > 0) { enemies[k].HitPoints -= heroBullets[j].Power; // Apply an increased push back effect if (!(enemies[k] instanceof Bruiser)) { enemies[k].y -= 12; // Push the drone upwards slightly more } enemies[k].pulseEffect = true; // Trigger pulse effect heroBullets[j].destroy(); heroBullets.splice(j, 1); if (enemies[k].HitPoints <= 0) { if (enemies[k] instanceof Drone) { // Create drone pieces upon destruction var centerPiece = new DronePiece('DroneCenterPart'); centerPiece.x = enemies[k].x; centerPiece.y = enemies[k].y; game.addChild(centerPiece); var leftPiece = new DronePiece('DroneLeftPart'); leftPiece.x = enemies[k].x - 40; // Increase spread leftPiece.y = enemies[k].y; game.addChild(leftPiece); var rightPiece = new DronePiece('DroneRightPart'); rightPiece.x = enemies[k].x + 40; // Increase spread rightPiece.y = enemies[k].y; game.addChild(rightPiece); } else if (enemies[k] instanceof Bruiser) { // Create bruiser pieces upon destruction var centerPiece = new BruiserPiece('BruiserCenterPart'); centerPiece.x = enemies[k].x; centerPiece.y = enemies[k].y; game.addChild(centerPiece); var leftPiece = new BruiserPiece('BruiserLeftPart'); leftPiece.x = enemies[k].x - 40; // Increase spread leftPiece.y = enemies[k].y; var rightPiece = new BruiserPiece('BruiserRightPart'); rightPiece.x = enemies[k].x + 40; // Increase spread rightPiece.y = enemies[k].y; leftPiece.speedX = -Math.abs(leftPiece.speedX) * 1.5; // Increase force for left piece rightPiece.speedX = Math.abs(rightPiece.speedX) * 1.5; // Increase force for right piece game.addChild(leftPiece); game.addChild(rightPiece); } enemies[k].destroy(); enemies.splice(k, 1); LK.setScore(LK.getScore() + 1); scoreTxt.setText(LK.getScore()); } break; } } } // Spawn Blasters occasionally if (LK.ticks % 240 == 0) { var newBlaster = new Blaster(); newBlaster.x = 2048 * 0.21 + Math.random() * (2048 * 0.55); // Adjusted x position within the Road area with 5% margin newBlaster.y = -newBlaster.height; // Start just outside the top of the screen enemies.push(newBlaster); game.addChild(newBlaster); } // Fire bullets if (LK.ticks % 18 == 0) { var newBullet = new HeroBullet(); newBullet.x = hero.x; newBullet.y = hero.y - hero.height / 2; heroBullets.push(newBullet); game.addChild(newBullet); } // Generate dust particles in sync with player pulsing if (LK.ticks % 24 == 0) { var newDust = new Dust(); newDust.x = hero.x - hero.width / 4; // Move dust spawn position right half as much as the last move newDust.y = hero.y + hero.height / 2 * 0.93; // Move dust spawn point up 3% more game.addChild(newDust); } else if (LK.ticks % 24 == 12) { var newDust = new Dust(); newDust.x = hero.x + hero.width / 4; // Create another dust spawn point an equal distance in from the right of the player asset newDust.y = hero.y + hero.height / 2 * 0.93; // Move dust spawn point up 3% more game.addChild(newDust); } } }; // Handle touch input for hero movement var dragNode = null; game.down = function (x, y, obj) { if (isStarted) { dragNode = { x: hero.x, y: hero.y }; // Add a tilt-back effect during initial movement hero.rotation = x > hero.x ? Math.PI / 180 * -1 : Math.PI / 180 * 1; } }; game.move = function (x, y, obj) { if (isStarted && dragNode) { // Add a slight delay to the drag control to make the player feel like it has more weight dragNode.x += (x - dragNode.x) * 0.1; dragNode.y = hero.y; // Lock the y position to the hero's initial y position } }; game.up = function (x, y, obj) { dragNode = null; }; // Display score var scoreTxt = new Text2('0', { size: 150, fill: "#ffffff" }); scoreTxt.anchor.set(0.5, 0); LK.gui.top.addChild(scoreTxt); scoreTxt.setText(LK.getScore());
===================================================================
--- original.js
+++ change.js
@@ -29,10 +29,10 @@
anchorX: 0.5,
anchorY: 0.5,
x: self.x,
y: self.y,
- scaleX: 2,
- scaleY: 2,
+ scaleX: 1,
+ scaleY: 1,
alpha: 1,
visible: true
});
game.addChild(self.centralParticle);
View of a futuristic soldier from directly overhead. White armor with blue glowing cyberpunk details. Holding weapon forward.. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
The lights of a futuristic city in the dark at night. Very high above it looking straight down like from an airplane or a map. Background for an endlessly scrolling game.. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A big button that say Play to start playing a game. Use neon cyberpunk style.. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Overhead view. A hovering robot with a tapered midsection with two bulky arms with claw like hands and a giant red “eye” on top of its body. Looking straight down. Cyberpunk, black with red glowing highlights.. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Overhead view. A heavily armored attack robot. Two arms with large gauntlet type fists. Four large red glowing eyes. Three distinct parts, body and two arms. Symmetrical design. Birds Eye view above them looking down on their head. Simple shapes. Low detail. Cyberpunk, black with red glowing highlights.. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A red glowing line. Bright red core with subtle outer glow. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A blue transparent dome type shield. Simple graphics. Low details. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A ring of nuclear fire seen from overhead. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
A thin robot with goggles riding a hover-bike. Twin blaster guns mounted on front. Top down view. Birds Eye view. Cyberpunk with red glowing highlights... Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Battle drone, circular. White with blue glowing highlights. Birds Eye view from overhead. Cyberpunk. Simple shapes.. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
GameTheme
Music
TitleTheme
Music
HeroBlaster
Sound effect
Explosion
Sound effect
PowerUp
Sound effect
CloneSoldier
Sound effect
WeaponPowerUp
Sound effect
Drone
Sound effect
BinaryStorm
Sound effect
LaserCharge
Sound effect
LaserFire
Sound effect
BruiserStomp
Sound effect
RaiderSwoop
Sound effect
ShieldLevelUp
Sound effect
HeroHit
Sound effect
HeroScream
Sound effect