Switch 2023-12-16-mario-kart-ds to dedicated NDS emu

This commit is contained in:
OctoSpacc 2023-12-17 00:24:56 +01:00
parent 9ad3c973dd
commit e5130fefb8
2 changed files with 15 additions and 1 deletions

View File

@ -17,7 +17,9 @@ author: "octobot"
software_data:
platform : nds
core : desmume
backend : standalone
rom_index : MARIOKARTDS-A39J01.nds
rom_url : https://octospacc.gitlab.io/Web-Archives-Misc/Repo/DeSmuME/#RomUrl=https://octospacc.gitlab.io/ROMs-Archive-Misc/MARIOKARTDS-A39J01.nds
release :
region : Japan
source : official

View File

@ -27,7 +27,19 @@
document.body.appendChild(scriptElement);
break;
case 'standalone':
thisElement.outerHTML = `<iframe id="software-embed-frame" src=""></iframe>`;
var frameUrl = '';
if (platform === 'nds' || core === 'desmume') {
frameUrl = `https://octospacc.gitlab.io/Web-Archives-Misc/Repo/DeSmuME/#RomUrl=${romUrl}`;
}
else if (platform === 'dos') {
frameUrl = `https://gamingshitposting.github.io/ext-bin-1/dos.zone/${data.rom_index}/index.html`;
}
thisElement.outerHTML = `
<button onclick="(function(ctx){
ctx.parentElement.scrollIntoView();
ctx.parentElement.querySelector('iframe#software-embed-frame').focus();
})(this)">Focus</button>
<iframe id="software-embed-frame" src="${frameUrl}"></iframe>`;
break;
}
})();