User prompt
Updated Basic Enemy Animation Spawn Animation: The enemy smoothly fades in or scales up upon entering the screen. Downward Movement: Moves straight down at a fixed speed. Side-to-Side Drift: Slightly drifts left and right while descending, making it harder to hit. Destroy on Exit: Gets removed when it moves off-screen. Wave-Based Spawning: A finite number of basic enemy ships spawn per wave. Wave Transition: After all enemies in a wave are destroyed, the next wave starts with a short delay. ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
improve
User prompt
Improved Basic Enemy Animation Spawn Animation: The enemy fades in or scales up when entering the screen. Downward Movement: The enemy moves straight down at a fixed speed. Side-to-Side Drift: The enemy drifts slightly left and right while moving down, making it harder to hit. Destroy on Exit: The enemy is removed when off-screen. ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
mproved Basic Enemy Animation Spawn Animation: The enemy fades in or scales up when entering the screen. Downward Movement: The enemy moves straight down at a fixed speed. Side-to-Side Drift: The enemy drifts slightly left and right while moving down, making it harder to hit. Destroy on Exit: The enemy is removed when off-screen. ↪💡 Consider importing and using the following plugins: @upit/tween.v1
User prompt
Create a 2D space shooter game where the player pilots a high-tech spacecraft to defend the galaxy from waves of alien invaders and powerful bosses. The game should have classic arcade gameplay with modern visuals, smooth animations, and immersive sound effects. Game Features: Core Gameplay: The player's spaceship automatically shoots while the player controls movement (drag/swipe or joystick). Enemies appear in waves with increasing difficulty. Each level ends with a boss fight, requiring strategy to defeat. Enemy Types: Basic Drones – Weak but attack in numbers. Heavy Fighters – Move slowly but deal high damage. Fast Attackers – Swift movement, difficult to hit. Alien Motherships – Large bosses with unique attack patterns. Upgrades & Power-Ups: Weapon Upgrades – Spread shots, homing missiles, laser beams. Shields – Temporary invincibility. Speed Boosts – Increases maneuverability. Bombs – Destroys all enemies on screen. Graphics & Effects: Neon-style futuristic spaceship designs. Explosions and particle effects for impacts. Dynamic backgrounds with stars, asteroids, and cosmic elements. Game Modes: Endless Mode – Survive as long as possible. Story Mode – Complete missions to unlock new ships and weapons. Boss Rush Mode – Face all bosses in succession. Monetization (Optional): Rewarded ads for extra lives, power-ups. In-app purchases for new ships, skins, and weapons. Sound & Music: Futuristic, intense background music. Laser shooting and explosion sound effects.
Initial prompt
Galactic Defender: Alien Invasion
/****
* Classes
****/
// Class for enemy ships
var EnemyShip = Container.expand(function () {
var self = Container.call(this);
var enemyGraphics = self.attachAsset('enemyShip', {
anchorX: 0.5,
anchorY: 0.5
});
self.speed = 5;
self.update = function () {
self.y += self.speed;
if (self.y > 2732 + enemyGraphics.height) {
self.destroy();
enemyShips.splice(enemyShips.indexOf(self), 1);
}
};
});
// Class for player bullets
var PlayerBullet = Container.expand(function () {
var self = Container.call(this);
var bulletGraphics = self.attachAsset('playerBullet', {
anchorX: 0.5,
anchorY: 0.5
});
self.speed = -15;
self.update = function () {
self.y += self.speed;
if (self.y < -bulletGraphics.height) {
self.destroy();
playerBullets.splice(playerBullets.indexOf(self), 1);
}
};
});
//<Assets used in the game will automatically appear here>
//<Write imports for supported plugins here>
// Class for the player's ship
var PlayerShip = Container.expand(function () {
var self = Container.call(this);
var shipGraphics = self.attachAsset('playerShip', {
anchorX: 0.5,
anchorY: 0.5
});
self.speed = 10;
self.shoot = function () {
var bullet = new PlayerBullet();
bullet.x = self.x;
bullet.y = self.y - shipGraphics.height / 2;
game.addChild(bullet);
playerBullets.push(bullet);
};
});
/****
* Initialize Game
****/
var game = new LK.Game({
backgroundColor: 0x000000 //Init game with black background
});
/****
* Game Code
****/
// Arrays to keep track of game objects
var playerBullets = [];
var enemyShips = [];
// Create player ship
var player = game.addChild(new PlayerShip());
player.x = 2048 / 2;
player.y = 2732 - 200;
// Function to spawn enemies
function spawnEnemy() {
var enemy = new EnemyShip();
enemy.x = Math.random() * 2048;
enemy.y = -100;
game.addChild(enemy);
enemyShips.push(enemy);
}
// Game update loop
game.update = function () {
// Update player bullets
for (var i = playerBullets.length - 1; i >= 0; i--) {
playerBullets[i].update();
}
// Update enemy ships
for (var j = enemyShips.length - 1; j >= 0; j--) {
enemyShips[j].update();
}
// Check for collisions between player bullets and enemy ships
for (var k = playerBullets.length - 1; k >= 0; k--) {
for (var l = enemyShips.length - 1; l >= 0; l--) {
if (playerBullets[k].intersects(enemyShips[l])) {
playerBullets[k].destroy();
enemyShips[l].destroy();
playerBullets.splice(k, 1);
enemyShips.splice(l, 1);
break;
}
}
}
// Spawn enemies periodically
if (LK.ticks % 60 === 0) {
spawnEnemy();
}
};
// Handle player ship movement
game.move = function (x, y, obj) {
player.x = x;
};
// Handle shooting
game.down = function (x, y, obj) {
player.shoot();
};
A 2D top-down view of a futuristic player spaceship with a streamlined silver and blue body, glowing thrusters, and dual laser cannons. The design is sleek and modern for a space shooter game. Single Game Texture. 2d. Blank background. High contrast. No shadows
A 2D top-down view of an alien spaceship with a dark metallic body, glowing red energy cores, and sharp angular wings. The design is sleek and futuristic, suitable for a space shooter game.. Single Game Texture. 2d. Blank background. High contrast. No shadows
A 2D top-down view of a futuristic energy bullet for a space shooter game. The bullet is a glowing blue plasma projectile with a sleek, elongated shape and a slight energy trail behind it. The design is simple, bright, and high-speed-looking, suitable for fast-paced shooting gameplay. Single Game Texture. In-Game asset. Blank background. High contrast. No shadows
A 2D top-down view of a futuristic energy bullet for a space shooter game. The bullet is a glowing red plasma projectile elongated shape and a slight energy trail behind it. The design is simple, bright, and high-speed-looking, suitable for fast-paced shooting gameplay. Single Game Texture. In-Game asset. Blank background. High contrast. No shadows
A vibrant and dynamic 2D space background for a top-down space shooter game. The scene features a deep, dark space filled with glowing nebulae in shades of blue and purple, scattered distant stars, and swirling cosmic dust. A subtle parallax effect is suggested with faintly glowing planets and asteroids in the background. The atmosphere is slightly mysterious and futuristic, with soft light gradients to create depth. The overall tone is immersive but does not distract from gameplay, ensuring clear visibility of player and enemy ships.. Single Game Texture. Blank background. High contrast. No shadows
A vibrant and dynamic 2D space background for a top-down space shooter game. The scene features a deep, dark space filled with glowing nebulae in shades of blue and purple, scattered distant stars, and swirling cosmic dust. A subtle parallax effect is suggested with faintly glowing planets and asteroids in the background. The atmosphere is slightly mysterious and futuristic, with soft light gradients to create depth. The overall tone is immersive but does not distract from gameplay, ensuring clear visibility of player and enemy ships.. Single Game Texture. Blank background. High contrast. No shadows
powerup boll. Single Game Texture. Blank background. High contrast. No shadows