User prompt
Fix Bug: 'Uncaught TypeError: Cannot read properties of undefined (reading 'anchor')' in this line: 'messageText.anchor.set(.5, .5);' Line Number: 352
Code edit (1 edits merged)
Please save this source code
User prompt
add counter to track between games, every unique destroy waty of the box. it should just be a counter and add 1 when a new destroy method happened.
Code edit (1 edits merged)
Please save this source code
User prompt
create a global variable that adds 1 to the count every time the game is rest.
User prompt
Fix Bug: 'ReferenceError: globalScoreDisplay is not defined' in this line: 'globalScoreDisplay.updateScore(globalScore);' Line Number: 190
User prompt
Fix Bug: 'ReferenceError: globalScoreDisplay is not defined' in this line: 'globalScoreDisplay.updateScore(globalScore);' Line Number: 190
User prompt
Fix Bug: 'ReferenceError: globalScoreDisplay is not defined' in this line: 'globalScoreDisplay.updateScore(globalScore);' Line Number: 190
User prompt
Fix Bug: 'Uncaught ReferenceError: globalScore is not defined' in this line: 'var scoreText = new Text2(globalScore.toString(), {' Line Number: 3
User prompt
Fix Bug: 'TypeError: Cannot read properties of undefined (reading 'updateScore')' in this line: 'self.parent.globalScoreDisplay.updateScore(globalScore);' Line Number: 101
User prompt
Fix Bug: 'ReferenceError: globalScoreDisplay is not defined' in this line: 'globalScoreDisplay.updateScore(globalScore);' Line Number: 190
User prompt
show global score 300 pixels on top of deadoralive
User prompt
add a global score that will be persisten even after game reset
User prompt
show global score in the top of the screen
User prompt
add a global score count that will not reset when the game rests.
User prompt
add a counter to count axe intersects with box. only allow to intersect once per game.
User prompt
why is game restarted multiple times after axe intersects with box?
Code edit (4 edits merged)
Please save this source code
User prompt
console log when game is restarted
Code edit (1 edits merged)
Please save this source code
User prompt
when box is sliced, top part should move towards the upper right corner y bottom part to the bottom left.
Code edit (6 edits merged)
Please save this source code
User prompt
instead of game over, reste game after the box is destroyed.
Code edit (5 edits merged)
Please save this source code
User prompt
Fix Bug: 'Timeout.tick error: self.addChild is not a function' in this line: 'self.addChild(boxGraphics);' Line Number: 162
===================================================================
--- original.js
+++ change.js
@@ -97,9 +97,9 @@
}
if (self.children.length === 0) {
globalScore += 200;
LK.setScore(globalScore);
- globalScoreDisplay.updateScore(globalScore);
+ self.parent.globalScoreDisplay.updateScore(globalScore);
self.destroy();
}
}
lastTapTime = currentTime;
@@ -364,8 +364,9 @@
dragNode = null;
});
});
var globalScore = 0;
+var globalScoreDisplay = new GlobalScoreDisplay();
var Game = Container.expand(function () {
var self = Container.call(this);
self.axeIntersected = false;
var axe = self.addChild(new Axe());
8-bit. cartoon. red button. do not touch! Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
8-bit. cartoon. black tub stopper with chain. in game asset.. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
8-bit. cartoon. axe. in game asset. no shadow.. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Break in case of emergency square. Ax drawing inside. simple. 8-bit. cartoon. blackand white.. Single Game Texture. In-Game asset. 2d. Blank background. High contrast. No shadows.
Delete