User prompt
remove the particles
User prompt
make the particles render before the bus is rendered
User prompt
Fix Bug: 'TypeError: Cannot read properties of undefined (reading 'update')' in this line: 'bus.update();' Line Number: 176
User prompt
Fix Bug: 'Uncaught ReferenceError: bus is not defined' in this line: 'bus.x = 2048 / 2;' Line Number: 148
User prompt
render the bus on top of everything else
User prompt
Fix Bug: 'Uncaught ReferenceError: bus is not defined' in this line: 'self.addChild(bus);' Line Number: 132
User prompt
render the bus last
User prompt
render the particles first
User prompt
render the particles underneath everything else
User prompt
destroy particles that are dead
User prompt
make the particles disappear after 3 seconds
User prompt
make a particle trail behind the bus
User prompt
set the countdown timer to 15 every time
User prompt
only add one bomb with every point
User prompt
reduce the collision size of the bus
Code edit (2 edits merged)
Please save this source code
User prompt
set the start amount of bombs to 1
User prompt
make one more bomb appear with every point that is collected
User prompt
make the obstacles collision areas a lot smaller
Code edit (1 edits merged)
Please save this source code
User prompt
reduce the collision padding of the obstacless
User prompt
Fix Bug: 'TypeError: busBounds.intersects is not a function' in this line: 'if (busBounds.intersects(obstacleBounds)) {' Line Number: 89
User prompt
Fix Bug: 'TypeError: obstacles[i].getBounds(...).pad is not a function' in this line: 'var obstacleBounds = obstacles[i].getBounds().pad(-10);' Line Number: 84
===================================================================
--- original.js
+++ change.js
@@ -79,12 +79,8 @@
LK.showGameOver();
} else {
self.x = newX;
self.y = newY;
- var particle = new Particle();
- particle.x = self.x;
- particle.y = self.y;
- LK.stage.addChild(particle);
}
var maxRotationSpeed = 0.02;
if (self.speed > 0) {
var rotationChange = wheelRotation;
@@ -172,16 +168,8 @@
LK.on('tick', function () {
obstacles.forEach(function (obstacle) {
self.addChild(obstacle);
});
- var particle = new Particle();
- particle.x = bus.x;
- particle.y = bus.y;
- LK.stage.addChild(particle);
- var particle = new Particle();
- particle.x = bus.x;
- particle.y = bus.y;
- LK.stage.addChild(particle);
bus.update();
bus.move(steeringWheel.rotation);
bus.checkCollision(obstacles);
for (var i = 0; i < passengers.length; i++) {
Simple Car Steering Wheel. In-Game asset. 2d. Blank background. Svg
bomb Single Game Texture. In-Game asset. 2d. No shadows. flat. detailed
yellow bus stop symbol svg Single Game Texture. In-Game asset. 2d. No shadows. flat. detailed
yellow bus symbol svg. roof. top down. Single Game Texture. In-Game asset. 2d. No shadows. flat. detailed
dark transparent dust particle Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.