From c6bd6369670963fd057e88fddfc7ac0617ccc8e7 Mon Sep 17 00:00:00 2001 From: Alexey Nurgaliev Date: Wed, 30 Aug 2023 21:42:50 +0300 Subject: [PATCH] ability to disable .cue file creation --- data/emulator.js | 2 +- data/loader.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/data/emulator.js b/data/emulator.js index f33a9bc..38c1bf4 100644 --- a/data/emulator.js +++ b/data/emulator.js @@ -863,7 +863,7 @@ class EmulatorJS { } let resData = {}; - const needsCue = (["mednafen_psx", "mednafen_psx_hw", "mednafen_pce"].includes(this.getCore())); + const needsCue = (["mednafen_psx", "mednafen_psx_hw", "mednafen_pce"].includes(this.getCore())) && !this.config.disableCue; const altName = this.config.gameUrl.startsWith("blob:") ? (this.config.gameName || "game") : this.config.gameUrl.split('/').pop().split("#")[0].split("?")[0]; this.checkCompression(new Uint8Array(data), this.localization("Decompress Game Data"), (fileName, fileData) => { if (fileName.includes("/")) { diff --git a/data/loader.js b/data/loader.js index 90ae7eb..fa91710 100644 --- a/data/loader.js +++ b/data/loader.js @@ -79,6 +79,7 @@ config.backgroundColor = window.EJS_backgroundColor; config.controlScheme = window.EJS_controlScheme; config.threads = window.EJS_threads; + config.disableCue = window.EJS_disableCue; if (typeof window.EJS_language === "string" && window.EJS_language !== "en-US") { try {