User prompt
make a wall on the sides
User prompt
if you keep clicing you get out makewal to
User prompt
make th game more detailed
User prompt
make it wayyyy harder
User prompt
make the screen follow me
User prompt
make me keep move side ways
User prompt
make gravity and the player jumps when you click
User prompt
make a ground
User prompt
make the player go side ways continuasly and change the background to mach the playr
Initial prompt
geometry crash
===================================================================
--- original.js
+++ change.js
@@ -54,8 +54,12 @@
});
self.speed = 10;
self.update = function () {
// Player update logic
+ self.y += self.speed;
+ if (self.y > 2500) {
+ self.y = 2500;
+ }
};
});
/****
@@ -88,17 +92,13 @@
// Initialize bullets
var bullets = [];
// Handle player movement
game.down = function (x, y, obj) {
- player.x = x;
+ player.speed = -30;
};
// Handle shooting
game.up = function (x, y, obj) {
- var bullet = new Bullet();
- bullet.x = player.x;
- bullet.y = player.y;
- bullets.push(bullet);
- game.addChild(bullet);
+ player.speed = 10;
};
// Game update loop
game.update = function () {
// Update player