-
Notifications
You must be signed in to change notification settings - Fork 43
Description
Hi,
if I want to add bought Keen versions, like Keen5 or Keen6 I have to put files into the Android/data folder. Problem is, that since Android changed some security rules for this folder, this only works via adb (over USB or over WLAN).
Instead you could add the Android/media folder. Then you could move the files there with any Android file manager (like the stock file manager files).
In the file "FindFile.cpp" I found the following lines (at about line 500):
AddToFileList(&basesearchpaths, "/switch/CommanderGenius");
AddToFileList(&basesearchpaths, "romfs:/");
#else // all other systems (Linux, *BSD, OS/2, ...)
#ifdef ANDROID
//AddToFileList(&basesearchpaths, "${HOME}/SaveData");
AddToFileList(&basesearchpaths, SDL_AndroidGetExternalStoragePath());
AddToFileList(&basesearchpaths, SDL_AndroidGetInternalStoragePath());
AddToFileList(&basesearchpaths, "/storage/emulated/0/Android/data/net.sourceforge.clonekeenplus/files/SaveData");
#else
#ifdef ALTERNATE_HOME
AddToFileList(&basesearchpaths, ALTERNATE_HOThe line
AddToFileList(&basesearchpaths, SDL_AndroidGetExternalStoragePath());
adds the "Android/data" path to the search path list.
In the SDL there seems to be no method to get the "Android/media" path. But in the end, you only have to replace "Android/data" with "Android/media" I guess.
I have to admit, I am no expert in either C++ or Android programming. I didn’t even find out, how to compile this code for android. So I am not sure, if it works this way. Anyway, it would make it easier to add games to on Android.