Add title request functions to Emulator
This commit is contained in:
parent
6bd19518eb
commit
807c030f86
|
@ -415,6 +415,18 @@ bool Emulator::RestoreFromFile(const std::wstring& path) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool Emulator::TitleRequested() {
|
||||||
|
auto xam = kernel_state()->GetKernelModule<kernel::xam::XamModule>("xam.xex");
|
||||||
|
return xam->loader_data().launch_data_present;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Emulator::LaunchNextTitle() {
|
||||||
|
auto xam = kernel_state()->GetKernelModule<kernel::xam::XamModule>("xam.xex");
|
||||||
|
auto next_title = xam->loader_data().launch_path;
|
||||||
|
|
||||||
|
CompleteLaunch(L"", next_title);
|
||||||
|
}
|
||||||
|
|
||||||
bool Emulator::ExceptionCallbackThunk(Exception* ex, void* data) {
|
bool Emulator::ExceptionCallbackThunk(Exception* ex, void* data) {
|
||||||
return reinterpret_cast<Emulator*>(data)->ExceptionCallback(ex);
|
return reinterpret_cast<Emulator*>(data)->ExceptionCallback(ex);
|
||||||
}
|
}
|
||||||
|
|
|
@ -125,6 +125,10 @@ class Emulator {
|
||||||
bool SaveToFile(const std::wstring& path);
|
bool SaveToFile(const std::wstring& path);
|
||||||
bool RestoreFromFile(const std::wstring& path);
|
bool RestoreFromFile(const std::wstring& path);
|
||||||
|
|
||||||
|
// The game can request another title to be loaded.
|
||||||
|
bool TitleRequested();
|
||||||
|
void LaunchNextTitle();
|
||||||
|
|
||||||
void WaitUntilExit();
|
void WaitUntilExit();
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
Loading…
Reference in New Issue