Code edit (2 edits merged)
Please save this source code
User prompt
in initScoreState move scoreTxt to the center of the screen
User prompt
Please fix the bug: 'Uncaught TypeError: setInterval is not a function' in or related to this line: 'var qualityInterval = setInterval(function () {' Line Number: 820
User prompt
in initScoreState and handleScoreLoop, animate the averageQuality in scoreTxt from 0% to averageQuality
Code edit (3 edits merged)
Please save this source code
User prompt
in initScoreState, remove the background asset, just let the colot
User prompt
in initScoreState add the '%'
User prompt
in initScoreState, calculate the average quality usint the totals and write it in the score without decimals
User prompt
set the scoreTxt to "Average Quality :" and make it visible
User prompt
in initScoreState set the background to 0x8FA9B9
Code edit (1 edits merged)
Please save this source code
User prompt
in gameResultDown, if currentLevel and current round are the last, switch to initscorestate() instead of initNewRoundState();
Code edit (3 edits merged)
Please save this source code
User prompt
when levelManager.currentLevel >= this.levels.length switch to score state
User prompt
add a global vairable totalRound and cumulate the rounds in it
User prompt
add a global variable totalShots and cumulate the shots in it
User prompt
add a global variable totalScore and cumulate the score in it
Code edit (1 edits merged)
Please save this source code
Code edit (5 edits merged)
Please save this source code
User prompt
ok, now prevent clicks in result state during the first 2 seconds
Code edit (1 edits merged)
Please save this source code
User prompt
adapt the MovingTarget class to use the new arguments
User prompt
remove local revert in initNewRoundState set directly currentTargetRevert instead
User prompt
use currentTargetRevert instead of revert in initNewRoundState
Code edit (1 edits merged)
Please save this source code
===================================================================
--- original.js
+++ change.js
@@ -797,17 +797,17 @@
if (currentQuality >= averageQuality) {
LK.clearInterval(qualityInterval);
} else {
currentQuality++;
- scoreTxt.setText('Average Quality : ' + currentQuality + '%');
+ scoreTxt.setText('Average Quality\n' + currentQuality + '%');
}
}, 50); // Adjust the interval time as needed
}
function handleScoreLoop() {
// Update score elements
if (currentQuality < averageQuality) {
currentQuality++;
- scoreTxt.setText('Average Quality : ' + currentQuality + '%');
+ scoreTxt.setText('Average Quality\n' + currentQuality + '%');
}
}
function cleanScoreState() {
log("cleanScoreState...");
a forest.
flying Red-bellied Woodpecker.
flying Yellow-headed Blackbird.
flying Painted Bunting.
Underwater. only water and corals. NO animals
Countryside. 1 flower in foreground.
A Butterfly flying.
a fish swimming.
full dragonfly flying to the right.
full drone flying to the right.
a full hot air balloon with a basket flying to the right.
roofs of an empty modern city. day light
a satellite.
stary dark space. NO OBJECTS
a multitude of polaroids in bulk, with photos of birds, fishes, butterflies, planes, hot air baloons, satelites, dragonflies.....
A flying owl.
A flying parrot.
hippocampe.
shark. lateral view
diodon hystrix swimming. lateral view
fighting fish swimming. lateral view
a hang glider flying. full lateral view
un cerf-volant multicolore.
une coccinelle volante.
un scarabée vert irisé volant. side view
une gueppe volante. side view
un astronaute volant. full side view
une navette spaciale volante. full side view
un astéroïde volant dans l'espace. full side view
remove