From 76a40ef066fc5f608084b80e6fefeb62e43c123b Mon Sep 17 00:00:00 2001 From: twinaphex Date: Wed, 12 Feb 2014 17:29:20 +0100 Subject: [PATCH] (PSP) Add example for manually loading a ROM file so that we can skip past the menu --- frontend/platform/platform_psp.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/frontend/platform/platform_psp.c b/frontend/platform/platform_psp.c index 0785d3d2a3..8ae389bef2 100644 --- a/frontend/platform/platform_psp.c +++ b/frontend/platform/platform_psp.c @@ -102,6 +102,17 @@ static void system_deinit(void *data) sceKernelExitGame(); } +static void system_exec(const char *path, bool should_load_game) +{ +#if 0 + char path[256]; + snprintf(path, sizeof(path), "%s%s", default_paths.port_dir, "dkc.sfc"); + + strlcpy(g_extern.fullpath, path, sizeof(g_extern.fullpath)); + g_extern.lifecycle_state |= (1ULL << MODE_LOAD_GAME); +#endif +} + const frontend_ctx_driver_t frontend_ctx_psp = { get_environment_settings, /* get_environment_settings */ system_init, /* init */ @@ -109,7 +120,7 @@ const frontend_ctx_driver_t frontend_ctx_psp = { NULL, /* exitspawn */ NULL, /* process_args */ NULL, /* process_events */ - NULL, /* exec */ + system_exec, /* exec */ NULL, /* shutdown */ "psp", };