Code edit (1 edits merged)
Please save this source code
User prompt
Shin's Squishy Struggle
Initial prompt
Thanks for the creative idea! Just to clarify: you're imagining a **comical, cartoon-style** story where: * Shin the elephant **"eats"** the other animals in a silly, non-graphic way * The four animals (Nemo the corgi 🐶, Macchiato the cat 🐱, Carrot the bunny 🐰, Tiagra the tiger 🐯) are **not inside** his belly, but are somehow **"stuck" on top of it** * Shin is **digesting them comically** without them being literally swallowed — more like they're being absorbed or melted into his belly while they struggle * The tone is **funny and exaggerated**, not realistic or gory If that’s correct, here's the **comic script** for: --- ## 🐘 *"Shin’s Belly Absorbs Everything!"* 🐯🐰🐶🐱 *A bizarre, bouncy belly adventure!* --- ### **🟨 Panel 1:** *Scene: Shin the giant elephant just finished a huge meal. Nemo, Macchiato, Carrot, and Tiagra are caught off guard.* **Caption:** *Shin was VERY hungry...* **Shin:** *"Oops! I ate... everyone?"* --- ### **🟨 Panel 2:** *Shin lies down, patting his huge belly. But instead of being inside, the four animals are stuck ON the belly, half-sunk like it’s marshmallow slime.* **Macchiato (half-stuck):** *"Why is it... squishy?! Am I sinking?!"* **Tiagra (clawing upward):** *"THIS IS NOT HOW DIGESTION WORKS!"* --- ### **🟨 Panel 3:** *Carrot is bouncing like a trapped jellybean. Nemo is barking and sliding around.* **Carrot:** *"I DON’T WANT TO BECOME PART OF AN ELEPHANT!"* **Nemo:** *"MY PAWS! I CAN’T FEEL MY PAWS!"* --- ### **🟨 Panel 4:** *The belly starts absorbing them slowly like a squishy vacuum. Their tails and ears stick out, then start getting pulled in.* **Sound FX:** *“GLORRRB... SLURPPP...”* **Macchiato (only ears visible):** *"I REGRET EVERYTHING!!"* --- ### **🟨 Panel 5:** *Shin snores peacefully. Only small bulges and muffled voices are seen under his belly.* **Shin (sleep talking):** *"Mmm... spicy tiger... chewy corgi..."* **\[Tiny voice inside belly]:** *"We’re not snacks!! Let us out!!"* --- ### **🟨 Panel 6:** *A small sign pops out of Shin’s belly:* **Sign:** *"Do Not Disturb – Digesting Friends."* **Caption:** *Friendship has never been so... absorbent.* --- Would you like me to **turn this into actual comic-style images** using AI-generated artwork? I can make each panel illustrated based on this script. Just say **"Yes, make the images"**, or let me know if you want to change the style (cute, creepy, realistic, chibi, etc). With Video Animation And Without Game Animation And Without Escape Of Shin Belly
/**** * Plugins ****/ var tween = LK.import("@upit/tween.v1"); /**** * Classes ****/ // Animal class represents the characters crawling on the belly. var Animal = Container.expand(function (assetId) { var self = Container.call(this); // Public properties for velocity self.vx = 0; self.vy = 0; // Private properties for movement behavior var crawlSpeed = 1.5; // Constant speed at which animals crawl outwards var friction = 0.95; // Damping factor to slow down after a push // Attach the animal's graphic, centered. var graphics = self.attachAsset(assetId, { anchorX: 0.5, anchorY: 0.5 }); // Pushes the animal away from a tap point. self.push = function (tapX, tapY) { var dx = self.x - tapX; var dy = self.y - tapY; var distance = Math.sqrt(dx * dx + dy * dy); // The push is stronger if the tap is closer, up to a max radius. var maxPushRadius = 500; if (distance < maxPushRadius) { var pushStrength = 60; // Base strength of the push var force = (1 - distance / maxPushRadius) * pushStrength; // Apply force only if not directly on the tap point if (distance > 0) { self.vx += dx / distance * force; self.vy += dy / distance * force; } } }; // Called every frame by the LK engine. self.update = function () { // Calculate vector to crawl outwards from the screen center. var centerX = 2048 / 2; var centerY = 2732 / 2; var dx_center = self.x - centerX; var dy_center = self.y - centerY; var dist_center = Math.sqrt(dx_center * dx_center + dy_center * dy_center); if (dist_center > 0) { // Add a constant outward crawl velocity. self.vx += dx_center / dist_center * crawlSpeed; self.vy += dy_center / dist_center * crawlSpeed; } // Apply friction to gradually reduce velocity. self.vx *= friction; self.vy *= friction; // Update the animal's position based on its velocity. self.x += self.vx; self.y += self.vy; // Rotate the animal to face the direction it's crawling. self.rotation = Math.atan2(self.y - centerY, self.x - centerX) + Math.PI / 2; }; return self; }); /**** * Initialize Game ****/ var game = new LK.Game({ backgroundColor: 0xF5DDC5 // A skin-tone color in case the belly image fails to load. }); /**** * Game Code ****/ // Tween library for animations like the ripple effect. // Playful background music. // Sound effect for the belly jiggle. // A shape for the visual ripple effect on tap. // The four animal friends trying to escape. // Shin's belly, serving as the game's background. // Global variables var animals = []; var scoreTxt; // Add the belly background, filling the screen. var belly = game.addChild(LK.getAsset('bellyBg', { x: 2048 / 2, y: 2732 / 2, anchorX: 0.5, anchorY: 0.5 })); // Set up the score display (based on time survived). scoreTxt = new Text2('0', { size: 120, fill: 0x333333 }); scoreTxt.anchor.set(0.5, 0); // Position the score at the top-center, with a small margin. scoreTxt.y = 50; LK.gui.top.addChild(scoreTxt); // Define the animals and their starting positions around the center. var animalAssets = ['corgi', 'cat', 'bunny', 'tiger']; var startPositions = [{ x: 2048 / 2 - 350, y: 2732 / 2 - 400 }, { x: 2048 / 2 + 350, y: 2732 / 2 - 400 }, { x: 2048 / 2 - 350, y: 2732 / 2 + 400 }, { x: 2048 / 2 + 350, y: 2732 / 2 + 400 }]; // Create and place the animals on the belly. for (var i = 0; i < animalAssets.length; i++) { var animal = new Animal(animalAssets[i]); animal.x = startPositions[i].x; animal.y = startPositions[i].y; game.addChild(animal); animals.push(animal); } // Handle player taps on the screen. game.down = function (x, y, obj) { // Play a jiggle sound. LK.getSound('jiggleSound').play(); // Create a visual ripple effect at the tap location. var ripple = game.addChild(LK.getAsset('ripple', { x: x, y: y, anchorX: 0.5, anchorY: 0.5, alpha: 0.8 })); // Animate the ripple to expand and fade out. tween(ripple, { scaleX: 5, scaleY: 5, alpha: 0 }, { duration: 400, easing: tween.easeOut, onFinish: function onFinish() { ripple.destroy(); } }); // Push all animals away from the tap. for (var i = 0; i < animals.length; i++) { animals[i].push(x, y); } }; // The main game loop, called every frame. game.update = function () { // The score is the number of seconds survived. var timeSurvived = Math.floor(LK.ticks / 60); LK.setScore(timeSurvived); scoreTxt.setText(String(timeSurvived)); // Check if any animal has reached the edge of the screen. for (var i = 0; i < animals.length; i++) { var animal = animals[i]; var halfWidth = animal.width / 2; var halfHeight = animal.height / 2; if (animal.x - halfWidth < 0 || animal.x + halfWidth > 2048 || animal.y - halfHeight < 0 || animal.y + halfHeight > 2732) { LK.showGameOver(); // Stop the update loop to prevent further actions after game over. game.update = function () {}; return; } } }; // Start the background music. LK.playMusic('bgMusic');
===================================================================
--- original.js
+++ change.js
@@ -1,6 +1,172 @@
-/****
+/****
+* Plugins
+****/
+var tween = LK.import("@upit/tween.v1");
+
+/****
+* Classes
+****/
+// Animal class represents the characters crawling on the belly.
+var Animal = Container.expand(function (assetId) {
+ var self = Container.call(this);
+ // Public properties for velocity
+ self.vx = 0;
+ self.vy = 0;
+ // Private properties for movement behavior
+ var crawlSpeed = 1.5; // Constant speed at which animals crawl outwards
+ var friction = 0.95; // Damping factor to slow down after a push
+ // Attach the animal's graphic, centered.
+ var graphics = self.attachAsset(assetId, {
+ anchorX: 0.5,
+ anchorY: 0.5
+ });
+ // Pushes the animal away from a tap point.
+ self.push = function (tapX, tapY) {
+ var dx = self.x - tapX;
+ var dy = self.y - tapY;
+ var distance = Math.sqrt(dx * dx + dy * dy);
+ // The push is stronger if the tap is closer, up to a max radius.
+ var maxPushRadius = 500;
+ if (distance < maxPushRadius) {
+ var pushStrength = 60; // Base strength of the push
+ var force = (1 - distance / maxPushRadius) * pushStrength;
+ // Apply force only if not directly on the tap point
+ if (distance > 0) {
+ self.vx += dx / distance * force;
+ self.vy += dy / distance * force;
+ }
+ }
+ };
+ // Called every frame by the LK engine.
+ self.update = function () {
+ // Calculate vector to crawl outwards from the screen center.
+ var centerX = 2048 / 2;
+ var centerY = 2732 / 2;
+ var dx_center = self.x - centerX;
+ var dy_center = self.y - centerY;
+ var dist_center = Math.sqrt(dx_center * dx_center + dy_center * dy_center);
+ if (dist_center > 0) {
+ // Add a constant outward crawl velocity.
+ self.vx += dx_center / dist_center * crawlSpeed;
+ self.vy += dy_center / dist_center * crawlSpeed;
+ }
+ // Apply friction to gradually reduce velocity.
+ self.vx *= friction;
+ self.vy *= friction;
+ // Update the animal's position based on its velocity.
+ self.x += self.vx;
+ self.y += self.vy;
+ // Rotate the animal to face the direction it's crawling.
+ self.rotation = Math.atan2(self.y - centerY, self.x - centerX) + Math.PI / 2;
+ };
+ return self;
+});
+
+/****
* Initialize Game
-****/
+****/
var game = new LK.Game({
- backgroundColor: 0x000000
-});
\ No newline at end of file
+ backgroundColor: 0xF5DDC5 // A skin-tone color in case the belly image fails to load.
+});
+
+/****
+* Game Code
+****/
+// Tween library for animations like the ripple effect.
+// Playful background music.
+// Sound effect for the belly jiggle.
+// A shape for the visual ripple effect on tap.
+// The four animal friends trying to escape.
+// Shin's belly, serving as the game's background.
+// Global variables
+var animals = [];
+var scoreTxt;
+// Add the belly background, filling the screen.
+var belly = game.addChild(LK.getAsset('bellyBg', {
+ x: 2048 / 2,
+ y: 2732 / 2,
+ anchorX: 0.5,
+ anchorY: 0.5
+}));
+// Set up the score display (based on time survived).
+scoreTxt = new Text2('0', {
+ size: 120,
+ fill: 0x333333
+});
+scoreTxt.anchor.set(0.5, 0);
+// Position the score at the top-center, with a small margin.
+scoreTxt.y = 50;
+LK.gui.top.addChild(scoreTxt);
+// Define the animals and their starting positions around the center.
+var animalAssets = ['corgi', 'cat', 'bunny', 'tiger'];
+var startPositions = [{
+ x: 2048 / 2 - 350,
+ y: 2732 / 2 - 400
+}, {
+ x: 2048 / 2 + 350,
+ y: 2732 / 2 - 400
+}, {
+ x: 2048 / 2 - 350,
+ y: 2732 / 2 + 400
+}, {
+ x: 2048 / 2 + 350,
+ y: 2732 / 2 + 400
+}];
+// Create and place the animals on the belly.
+for (var i = 0; i < animalAssets.length; i++) {
+ var animal = new Animal(animalAssets[i]);
+ animal.x = startPositions[i].x;
+ animal.y = startPositions[i].y;
+ game.addChild(animal);
+ animals.push(animal);
+}
+// Handle player taps on the screen.
+game.down = function (x, y, obj) {
+ // Play a jiggle sound.
+ LK.getSound('jiggleSound').play();
+ // Create a visual ripple effect at the tap location.
+ var ripple = game.addChild(LK.getAsset('ripple', {
+ x: x,
+ y: y,
+ anchorX: 0.5,
+ anchorY: 0.5,
+ alpha: 0.8
+ }));
+ // Animate the ripple to expand and fade out.
+ tween(ripple, {
+ scaleX: 5,
+ scaleY: 5,
+ alpha: 0
+ }, {
+ duration: 400,
+ easing: tween.easeOut,
+ onFinish: function onFinish() {
+ ripple.destroy();
+ }
+ });
+ // Push all animals away from the tap.
+ for (var i = 0; i < animals.length; i++) {
+ animals[i].push(x, y);
+ }
+};
+// The main game loop, called every frame.
+game.update = function () {
+ // The score is the number of seconds survived.
+ var timeSurvived = Math.floor(LK.ticks / 60);
+ LK.setScore(timeSurvived);
+ scoreTxt.setText(String(timeSurvived));
+ // Check if any animal has reached the edge of the screen.
+ for (var i = 0; i < animals.length; i++) {
+ var animal = animals[i];
+ var halfWidth = animal.width / 2;
+ var halfHeight = animal.height / 2;
+ if (animal.x - halfWidth < 0 || animal.x + halfWidth > 2048 || animal.y - halfHeight < 0 || animal.y + halfHeight > 2732) {
+ LK.showGameOver();
+ // Stop the update loop to prevent further actions after game over.
+ game.update = function () {};
+ return;
+ }
+ }
+};
+// Start the background music.
+LK.playMusic('bgMusic');
\ No newline at end of file