From e65ad62b760d572baee74f0d30aac037fb6b196f Mon Sep 17 00:00:00 2001 From: Tom Boullay Date: Tue, 12 May 2026 11:45:43 +0200 Subject: [PATCH 1/2] chore: add three devtools debug mode --- package.json | 1 + vite.config.ts | 46 +++++++++++++++++++++++++++++++++------------- 2 files changed, 34 insertions(+), 13 deletions(-) diff --git a/package.json b/package.json index 79b36cf..883e55c 100644 --- a/package.json +++ b/package.json @@ -8,6 +8,7 @@ }, "scripts": { "dev": "vite", + "dev:three-debug": "vite --mode three-debug --host 0.0.0.0", "build": "tsc -b && vite build", "lint": "eslint .", "lint:fix": "eslint . --fix", diff --git a/vite.config.ts b/vite.config.ts index 64c09f7..b7c246c 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -9,6 +9,9 @@ import { parseMapNodes } from "./src/utils/map/mapNodeValidation"; import { parseSrt } from "./src/utils/subtitles/parseSrt"; const __dirname = fileURLToPath(new URL(".", import.meta.url)); +const THREE_SOURCE_ENTRY = fileURLToPath( + new URL("./node_modules/three/src/Three.js", import.meta.url), +); const MAX_MAP_PAYLOAD_BYTES = 1024 * 1024; const MAX_SRT_PAYLOAD_BYTES = 256 * 1024; @@ -634,18 +637,35 @@ function resolvePublicPath(publicPath: string): string | null { return resolvedPath; } -export default defineConfig({ - plugins: [ - react(), - saveMapPlugin(), - saveSrtPlugin(), - saveDialogueManifestPlugin(), - saveCinematicManifestPlugin(), - validateDialoguesPlugin(), - ], - resolve: { - alias: { - "@": fileURLToPath(new URL("./src", import.meta.url)), +export default defineConfig(({ mode }) => { + const isThreeDebug = mode === "three-debug"; + + return { + plugins: [ + react(), + saveMapPlugin(), + saveSrtPlugin(), + saveDialogueManifestPlugin(), + saveCinematicManifestPlugin(), + validateDialoguesPlugin(), + ], + resolve: { + alias: [ + { + find: "@", + replacement: fileURLToPath(new URL("./src", import.meta.url)), + }, + ...(isThreeDebug + ? [{ find: /^three$/, replacement: THREE_SOURCE_ENTRY }] + : []), + ], }, - }, + ...(isThreeDebug + ? { + optimizeDeps: { + exclude: ["three"], + }, + } + : {}), + }; }); From 832f8b59be9b8e4cfeaace65ed09c5b271ea4aa7 Mon Sep 17 00:00:00 2001 From: Tom Boullay Date: Tue, 12 May 2026 15:38:04 +0200 Subject: [PATCH 2/2] Update repairMissions.ts --- src/data/gameplay/repairMissions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/data/gameplay/repairMissions.ts b/src/data/gameplay/repairMissions.ts index 0a9251e..78654d6 100644 --- a/src/data/gameplay/repairMissions.ts +++ b/src/data/gameplay/repairMissions.ts @@ -52,7 +52,7 @@ export const REPAIR_MISSIONS: Record = { description: "Repair the damaged cooling module before relaunching the bike", modelPath: "/models/ebike/model.gltf", - modelScale: 0.0055, + modelScale: 0.50, stageUiPath: "/assets/UI/ebike.webm", interactUiPath: REPAIR_INTERACT_UI_PATH, brokenUiPath: REPAIR_BROKEN_UI_PATH,