From 80dfd90ee5d754e1667a00b85e826e4f8e35cc12 Mon Sep 17 00:00:00 2001 From: rizkyaz0 Date: Sat, 3 Oct 2026 07:02:29 +0700 Subject: [PATCH] Jaga boot bila feel.js gagal dimuat (cadangan Feel tanpa efek) agar start dingin offline tidak mematikan game --- game.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/game.js b/game.js index b947f27..d532eda 100644 --- a/game.js +++ b/game.js @@ -22,7 +22,14 @@ const KITS = { ...(M ? { mira: M } : {}), ...(C ? { cora: C } : {}), ...(N ? { naja: N } : {}), ...(HD ? { haldor: HD } : {}), ...(Z ? { zanni: Z } : {}), ...(IS ? { isolde: IS } : {}), ...(RH ? { rhea: RH } : {}), ...(SO ? { solan: SO } : {}), ...(NB ? { nib: NB } : {}), ...(ED ? { edda: ED } : {}), ...(BW ? { browo: BW } : {}), ...Object.fromEntries(Object.entries(CF).map(([id, d]) => [id, cfKit(d)])) }; let manifest = window.MECHA_MANIFEST || window.SPRITE_MANIFEST || null, metrics = window.MECHA_METRICS || null; let selectedCharacter = 'arco', aiEnabled = !!F, fenrCutin = null, hudIdentity = ''; - const Rules = window.MatchRules, Feel = window.Feel; + // Cadangan bila feel.js gagal dimuat (mis. start dingin offline): tanpa rasa kena (hit-stop, getaran, K.O. slow-motion, angka, peringkat), tetapi game tetap hidup. + function feelFallback() { + const no = () => {}, h = { stop: 0, trauma: 0, kick: 0, flash: 0, size: 1, ripple: 0 }; + return { table: { medium: 10, colors: {}, hit: { medium: h, ultimate: h } }, classify: () => 'light', hit: () => h, rankOf: () => '', kickAt: no, kickOffset: () => ({ x: 0, y: 0 }), ripple: no, drawRipples: no, drawNumbers: no, tick: no, reset: no, comboHud: no, + ageNumbers: (list, dt) => { for (let i = list.length - 1; i >= 0; i--) if ((list[i].life -= dt) <= 0) list.splice(i, 1); }, + ko: { start: no, scale: () => 1, zoom: () => 1, drawOverlay: no, state: { on: false, cfg: { trauma: 0 } } } }; + } + const Rules = window.MatchRules, Feel = window.Feel || feelFallback(); let opponentCharacter = 'fenr', difficulty = 'medium', stageId = 'bellora', menuOpen = !!window.FRONTEND_ENABLED; let match = Rules?.create('training') || null, roundAnnouncer = null; const roundCues = [];