Attempt to load VFS in headless on Android.

Otherwise we don't get fonts, and savestates fail to load.
This commit is contained in:
Unknown W. Brackets 2014-03-25 00:49:03 -07:00
parent 36c3a0dd68
commit 4c35c1bb13

View file

@ -6,6 +6,7 @@
#include <cstdlib>
#include <limits>
#include "file/zip_read.h"
#include "Common/FileUtil.h"
#include "Core/Config.h"
#include "Core/Core.h"
@ -375,6 +376,16 @@ int main(int argc, const char* argv[])
if (screenshotFilename != 0)
headlessHost->SetComparisonScreenshot(screenshotFilename);
#ifdef ANDROID
// For some reason the debugger installs it with this name?
if (File::Exists("/data/app/org.ppsspp.ppsspp-2.apk")) {
VFSRegister("", new ZipAssetReader("/data/app/org.ppsspp.ppsspp-2.apk", "assets/"));
}
if (File::Exists("/data/app/org.ppsspp.ppsspp.apk")) {
VFSRegister("", new ZipAssetReader("/data/app/org.ppsspp.ppsspp.apk", "assets/"));
}
#endif
if (stateToLoad != NULL)
SaveState::Load(stateToLoad);