User prompt
only increase the vertical speed for each successive level by 1.1
User prompt
reduce the increase in vertical speed for each progressive level
User prompt
increase the initial angle of the arrow by 5 degrees relative to the aim.
User prompt
Reduce the initial angle of the arrow by 15 degrees relative to the aim.
User prompt
reduce the initial angle of the arrow by 5 degrees relative to the aim
User prompt
Reduce the increase in speed of vertical increment each level for the target even more
User prompt
reduce the increase in speed of vertical increment each level
User prompt
slow down the vertical increment for each level
User prompt
slow down the vertical movement increment
User prompt
when the target has eased into it's new position, move it up and down like before
User prompt
after moving to it's new position continue the up and down behaviour as before
User prompt
when the target is being repositioned to hit it's new position after being hit, ease it it it's new position over .5 second
User prompt
make the starting position of the particles be the end point of the arrow when it hits the target
User prompt
make the particles fade away as they animate
User prompt
ad 10 particles all going to random positions instead of just 1
User prompt
make the particle move 500% faster
User prompt
remove the particle when it has reached the end point
User prompt
remove after 10th of second
User prompt
remove the fucking particle after 1 second
User prompt
make the particle move faster and remove after 1 second of animation
User prompt
when arrow hits target add a firework particle to the x and y of the target, then animate/move/transport the particle to a new random position on screen 300 pixels away, the time to travel this distance should be 1 second then remove it
User prompt
when arrow hits target add 10 firework particles to the same position of the target when, then travel these particles away from the initial position at a random angle until each has travelled 300 pixels over a period of 1 second from the starting point hen remove them from the screen
User prompt
when arrow hits target add 10 firework particles to the same position of the target when, then move these particles away from the initial position at a random angle until each has travelled 300 pixels then remove them
User prompt
make it an explosion for fucks sake
User prompt
in addition to the firework, add an explosion of stars that updates with frame rate when target is hit
===================================================================
--- original.js
+++ change.js
@@ -1,18 +1,20 @@
-var Explosion = Container.expand(function () {
+var FireworkParticle = Container.expand(function () {
var self = Container.call(this);
- var explosionGraphics = self.createAsset('explosion', 'Explosion Graphics', .5, .5);
- LK.setTimeout(function () {
- self.destroy();
- }, 1000);
+ var fireworkGraphics = self.createAsset('fireworkParticle', 'Firework Particle Graphics', .5, .5);
+ self.distanceTraveled = 0;
+ self.maxDistance = 300;
+ self.speed = 5;
+ self.moveAngle = Math.random() * 2 * Math.PI;
+ self.move = function () {
+ self.x += self.speed * Math.cos(self.moveAngle);
+ self.y += self.speed * Math.sin(self.moveAngle);
+ self.distanceTraveled += self.speed;
+ if (self.distanceTraveled >= self.maxDistance) {
+ self.destroy();
+ }
+ };
});
-var Firework = Container.expand(function () {
- var self = Container.call(this);
- var fireworkGraphics = self.createAsset('firework', 'Firework Graphics', .5, .5);
- LK.setTimeout(function () {
- self.destroy();
- }, 1000);
-});
var Player = Container.expand(function () {
var self = Container.call(this);
var playerGraphics = self.createAsset('player', 'Player Graphics', .5, .5);
});
@@ -110,17 +112,13 @@
target.scale.y *= 0.9;
}
target.speed *= 1.05;
target.x = Math.random() * (2048 * 0.2) + 2048 * 0.7;
- var firework = new Firework();
- firework.x = arrows[a].x;
- firework.y = arrows[a].y;
- self.addChild(firework);
for (var i = 0; i < 10; i++) {
- var explosion = new Explosion();
- explosion.x = arrows[a].x + Math.random() * 50 - 25;
- explosion.y = arrows[a].y + Math.random() * 50 - 25;
- self.addChild(explosion);
+ var fireworkParticle = new FireworkParticle();
+ fireworkParticle.x = target.x;
+ fireworkParticle.y = target.y;
+ self.addChild(fireworkParticle);
}
arrows[a].destroy();
arrows.splice(a, 1);
player.y = Math.random() * (2732 / 2 + 300 - (2732 / 2 - 300)) + 2732 / 2 - 300;
a green field background
a target roundel viewed from the side
plain gold star, no outline Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a cartoon archers bow viewed from the side Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
a long cartoon arrow with gold shaft and steel point Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.