fix psx control mapping showing defaults

This commit is contained in:
Joe Thundercheeks 2025-10-20 00:04:48 -04:00 committed by GitHub
parent 8c750dde40
commit 9bfa915370
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -4,7 +4,7 @@ class EmulatorJS {
"atari5200": ["a5200"],
"vb": ["beetle_vb"],
"nds": ["melonds", "desmume", "desmume2015"],
"arcade": ["fbneo", "fbalpha2012_cps1", "fbalpha2012_cps2", "same_cdi"],
"arcade": ["fbneo", "fbalpha2012_cps1", "fbalpha2012_cps2"],
"nes": ["fceumm", "nestopia"],
"gb": ["gambatte"],
"coleco": ["gearcoleco"],
@ -940,9 +940,6 @@ class EmulatorJS {
} else if (createCueFile && supportsExt("m3u") && supportsExt("cue")) {
this.fileName = this.gameManager.createCueFile(fileNames);
}
if (this.getCore(true) === "dos" && !this.config.disableBatchBootup) {
this.fileName = this.gameManager.writeBootupBatchFile();
}
resolve();
});
}
@ -2827,6 +2824,31 @@ class EmulatorJS {
{ id: 17, label: this.localization("STICK LEFT") },
{ id: 16, label: this.localization("STICK RIGHT") },
];
} else if ("psx" === this.getControlScheme()) {
buttons = [
{ id: 9, label: this.localization("\u25B3") }, // △
{ id: 1, label: this.localization("\u25A1") }, // □
{ id: 0, label: this.localization("\uFF58") }, //
{ id: 8, label: this.localization("\u25CB") }, // ○
{ id: 2, label: this.localization("SELECT") },
{ id: 3, label: this.localization("START") },
{ id: 4, label: this.localization("UP") },
{ id: 5, label: this.localization("DOWN") },
{ id: 6, label: this.localization("LEFT") },
{ id: 7, label: this.localization("RIGHT") },
{ id: 10, label: this.localization("L1") },
{ id: 11, label: this.localization("R1") },
{ id: 12, label: this.localization("L2") },
{ id: 13, label: this.localization("R2") },
{ id: 19, label: this.localization("L STICK UP") },
{ id: 18, label: this.localization("L STICK DOWN") },
{ id: 17, label: this.localization("L STICK LEFT") },
{ id: 16, label: this.localization("L STICK RIGHT") },
{ id: 23, label: this.localization("R STICK UP") },
{ id: 22, label: this.localization("R STICK DOWN") },
{ id: 21, label: this.localization("R STICK LEFT") },
{ id: 20, label: this.localization("R STICK RIGHT") },
];
} else {
buttons = [
{ id: 0, label: this.localization("B") },
@ -7244,4 +7266,4 @@ class EmulatorJS {
})
}
}
window.EmulatorJS = EmulatorJS;
window.EmulatorJS = EmulatorJS;