From 92a0edabef7a97d0ab4973c58f952b326d6d3fdf Mon Sep 17 00:00:00 2001
From: Renan LE CARO
Date: Tue, 1 Apr 2025 18:33:58 +0200
Subject: [PATCH] Build 29058753
---
Readme.md | 1 +
app/build.gradle.kts | 4 ++--
app/src/main/assets/index.html | 2 +-
dist/index.html | 28 +++++++++++++---------------
src/PWA/sw-b71.js | 2 +-
src/data/version.json | 2 +-
src/game.less | 3 +--
src/game.ts | 2 +-
src/gameStateMutators.ts | 2 +-
src/game_utils.ts | 10 +++++-----
src/render.ts | 8 ++++----
11 files changed, 31 insertions(+), 33 deletions(-)
diff --git a/Readme.md b/Readme.md
index 9e56273..65c1e99 100644
--- a/Readme.md
+++ b/Readme.md
@@ -27,6 +27,7 @@ Break colourful bricks, catch bouncing coins and select powerful upgrades !
- keep high score of past runs
- tooltip on stats
+- fixed : looping didn't work
## 29058469
diff --git a/app/build.gradle.kts b/app/build.gradle.kts
index 35bb074..57af725 100644
--- a/app/build.gradle.kts
+++ b/app/build.gradle.kts
@@ -11,8 +11,8 @@ android {
applicationId = "me.lecaro.breakout"
minSdk = 21
targetSdk = 34
- versionCode = 29058637
- versionName = "29058637"
+ versionCode = 29058753
+ versionName = "29058753"
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
vectorDrawables {
useSupportLibrary = true
diff --git a/app/src/main/assets/index.html b/app/src/main/assets/index.html
index 344a248..c8f792e 100644
--- a/app/src/main/assets/index.html
+++ b/app/src/main/assets/index.html
@@ -1 +1 @@
-Breakout 71
\ No newline at end of file
+Breakout 71
\ No newline at end of file
diff --git a/dist/index.html b/dist/index.html
index dc6d193..eb910ea 100644
--- a/dist/index.html
+++ b/dist/index.html
@@ -1409,7 +1409,7 @@ restart(window.location.search.includes("stressTest") && {
bigger_explosions: 10,
sapper: 3
},
- mode: "short"
+ mode: "long"
} || {
mode: "short"
});
@@ -1460,7 +1460,7 @@ const upgrades = (0, _upgrades.rawUpgrades).map((u)=>({
}));
},{"./data/palette.json":"ktRBU","./data/levels.json":"8JSUc","./data/version.json":"iyP6E","./upgrades":"1u3Dx","./getLevelBackground":"7OIPf","./levelIcon":"6rQoT","@parcel/transformer-js/src/esmodule-helpers.js":"gkKU3"}],"iyP6E":[function(require,module,exports,__globalThis) {
-module.exports = JSON.parse("\"29058637\"");
+module.exports = JSON.parse("\"29058753\"");
},{}],"1u3Dx":[function(require,module,exports,__globalThis) {
var parcelHelpers = require("@parcel/transformer-js/src/esmodule-helpers.js");
@@ -2656,7 +2656,7 @@ function pickedUpgradesHTMl(gameState) {
${u.name}
${u.help(Math.max(1, gameState.perks[u.id]))}
- ${bars.reverse().join('')}
+ ${bars.reverse().join("")}
`
};
@@ -3305,14 +3305,12 @@ frames = 1) {
gameState.winAt && gameState.levelTime > gameState.winAt || // instant win condition
gameState.levelTime && !remainingBricks && !liveCount(gameState.coins)) {
if (gameState.currentLevel + 1 < (0, _gameUtils.max_levels)(gameState)) setLevel(gameState, gameState.currentLevel + 1);
- else {
- gameState.loop, gameState.mode;
- (0, _gameOver.gameOver)((0, _i18N.t)("gameOver.7_loop.title", {
- loop: gameState.loop
- }), (0, _i18N.t)("gameOver.7_loop.summary", {
- score: gameState.score
- }));
- }
+ else if (gameState.loop < (gameState.mode === "long" ? 7 : 0)) gotoNextLoop(gameState);
+ else (0, _gameOver.gameOver)((0, _i18N.t)("gameOver.7_loop.title", {
+ loop: gameState.loop
+ }), (0, _i18N.t)("gameOver.7_loop.summary", {
+ score: gameState.score
+ }));
} else if (gameState.running || gameState.levelTime) {
const coinRadius = Math.round(gameState.coinSize / 2);
forEachLiveOne(gameState.coins, (coin, coinIndex)=>{
@@ -3758,16 +3756,16 @@ function render(gameState) {
/
` : "") + ((0, _options.isOptionOn)("show_stats") ? `
- 0.9 && "good" || ""}" data-tooltip="${(0, _i18N.t)('play.stats.coins_catch_rate')}">
+ 0.9 && "good" || ""}" data-tooltip="${(0, _i18N.t)("play.stats.coins_catch_rate")}">
${Math.floor(catchRate * 100)}%
/
-
+
${Math.ceil(gameState.levelTime / 1000)}s
/
-
+
${gameState.levelWallBounces} B
/
-
+
${gameState.levelMisses} M
/
` : "") + `$${gameState.score}`;
diff --git a/src/PWA/sw-b71.js b/src/PWA/sw-b71.js
index 62ba78c..fd1ba18 100644
--- a/src/PWA/sw-b71.js
+++ b/src/PWA/sw-b71.js
@@ -1,5 +1,5 @@
// The version of the cache.
-const VERSION = "29058637";
+const VERSION = "29058753";
// The name of the cache
const CACHE_NAME = `breakout-71-${VERSION}`;
diff --git a/src/data/version.json b/src/data/version.json
index 1b9acb4..ce4b0d1 100644
--- a/src/data/version.json
+++ b/src/data/version.json
@@ -1 +1 @@
-"29058637"
+"29058753"
diff --git a/src/game.less b/src/game.less
index 3e1499b..166c598 100644
--- a/src/game.less
+++ b/src/game.less
@@ -61,12 +61,11 @@ body {
color: white;
transition: color 0.3s;
- &.active .score{
+ &.active .score {
color: gold;
transition: color 0.01s;
}
-
span {
color: rgba(255, 255, 255, 0.8);
diff --git a/src/game.ts b/src/game.ts
index e46a1e8..61d4920 100644
--- a/src/game.ts
+++ b/src/game.ts
@@ -989,7 +989,7 @@ restart(
sapper: 3,
// unbounded: 1,
},
- mode: "short",
+ mode: "long",
}) || {
mode: "short",
},
diff --git a/src/gameStateMutators.ts b/src/gameStateMutators.ts
index cb6b3d8..5d054d5 100644
--- a/src/gameStateMutators.ts
+++ b/src/gameStateMutators.ts
@@ -1027,7 +1027,7 @@ export function gameStateTick(
) {
if (gameState.currentLevel + 1 < max_levels(gameState)) {
setLevel(gameState, gameState.currentLevel + 1);
- } else if (gameState.loop < gameState.mode === "long" ? 7 : 0) {
+ } else if (gameState.loop < (gameState.mode === "long" ? 7 : 0)) {
gotoNextLoop(gameState);
} else {
gameOver(
diff --git a/src/game_utils.ts b/src/game_utils.ts
index 62b5304..e8aaae7 100644
--- a/src/game_utils.ts
+++ b/src/game_utils.ts
@@ -85,14 +85,14 @@ export function pickedUpgradesHTMl(gameState: GameState) {
.map((u) => {
const newMax = Math.max(0, u.max - gameState.bannedPerks[u.id]);
- let bars =[];
+ let bars = [];
for (let i = 0; i < Math.max(u.max, newMax, gameState.perks[u.id]); i++) {
if (i < gameState.perks[u.id]) {
- bars .push('');
+ bars.push('');
} else if (i < newMax) {
- bars .push('');
+ bars.push('');
} else {
- bars .push('');
+ bars.push('');
}
}
@@ -106,7 +106,7 @@ export function pickedUpgradesHTMl(gameState: GameState) {
${u.name}
${u.help(Math.max(1, gameState.perks[u.id]))}
- ${bars.reverse().join('')}
+ ${bars.reverse().join("")}
`,
};
diff --git a/src/render.ts b/src/render.ts
index c61af56..34b3096 100644
--- a/src/render.ts
+++ b/src/render.ts
@@ -69,16 +69,16 @@ export function render(gameState: GameState) {
: "") +
(isOptionOn("show_stats")
? `
- 0.9 && "good") || ""}" data-tooltip="${t('play.stats.coins_catch_rate')}">
+ 0.9 && "good") || ""}" data-tooltip="${t("play.stats.coins_catch_rate")}">
${Math.floor(catchRate * 100)}%
/
-
+
${Math.ceil(gameState.levelTime / 1000)}s
/
-
+
${gameState.levelWallBounces} B
/
-
+
${gameState.levelMisses} M
/
`