N7Alpha / UnrealLibretro

A Libretro Frontend for Unreal Engine
MIT License
25 stars 8 forks source link

SwanStation and PCSX2 libretro cores not running and causing crashes #27

Open INT3GRA-YT opened 1 year ago

INT3GRA-YT commented 1 year ago

Hi, I try to use the swanstation and pcsx2 cores in my unreal project but crashes occurs with multiple error messages (which can't be pasted here at the time being) also I also want to know how to switch games in cores

Many thanks

INT3GRA-YT commented 1 year ago

PCSX2 core error code:

Fatal error: [File:C:/actions-runner/_work/UnrealLibretro/UnrealLibretro/UE_4.27/UnrealLibretro/HostProject/Plugins/UnrealLibretro/Source/UnrealLibretro/Private/sdlarch.cpp] [Line: 898] The core failed to load the content.

UE4Editor_UnrealLibretro!LibretroContext::load_game() [C:\actions-runner_work\UnrealLibretro\UnrealLibretro\UE_4.27\UnrealLibretro\HostProject\Plugins\UnrealLibretro\Source\UnrealLibretro\Private\sdlarch.cpp:900] UE4Editor_UnrealLibretro!::operator()() [C:\actions-runner_work\UnrealLibretro\UnrealLibretro\UE_4.27\UnrealLibretro\HostProject\Plugins\UnrealLibretro\Source\UnrealLibretro\Private\sdlarch.cpp:986] UE4Editor_UnrealLibretro!FLambdaRunnable::Run() [C:\actions-runner_work\UnrealLibretro\UnrealLibretro\UE_4.27\UnrealLibretro\HostProject\Plugins\UnrealLibretro\Source\UnrealLibretro\Private\LambdaRunnable.cpp:34] UE4Editor_Core UE4Editor_Core kernel32 ntdll

N7Alpha commented 1 year ago

I removed your EpicAccountId from your dump log since I don't know how sensitive that information is, but better safe than sorry.

There are a finite number of working cores. I'll add these to the list of broken cores soon. Unfortunately getting these working requires fairly advanced debugging skills and familiarity with this codebase. I document the process somewhat if you want to try it for yourself. The core failed to load the content error is from fairly early in the startup sequence for the core. From the content on this page I'm thinking you might just be missing bios files. If the files need to go into the libretro system folder then follow the advice here. Let me know if the bios thing fixes it. If not then post the new crash logs you get.


There is a single execution path that both loads the core and game in serial. So to load a new game for the core you have to call ULibretroCoreInstance::Shutdown() and then set ULibretroCoreInstance::ROMPath to your new ROM and then call Launch() or do the analogous thing in blueprints. If you're wanting to load a new game without fully restarting the core I don't support that currently although the libretro.h technically does I just don't allow for it to keep things slightly simpler.