Save game not work on Android sdk version 30

Hello everyone, according to the new Google policy, soon all applications should support SDK version 30, but the problem is that saves do not work in this version of SDK, has someone encountered this problem or knows how to solve it? I have the required permission to read and write files

I am also experiencing the same issue. Android is not saving any file, however, saves do work if ran in editor.

Brother have you found the solution to this problem??? I have searched alot but no hellp :frowning:

There is no problem, it turns out because of the new security system this is how it should work, after you pack the game with a key and for distribution, everything will work through google play

There is no problem, it turns out because of the new security system this is how it should work, after you pack the game with a key and for distribution, everything will work through google play

Really thanks for solution. But i am kinda confuse. I will be thankfull if you give me following information

  1. You are successfully saving game in android 11 using just “Write_External_storage” “Read_External_Storage” permissions???

  2. Or you used “Manage_External_Storage” Permission??

  3. Or you are Requesting Write/Read Permissions in runtime through Blueprint node “Request Permission” ??

If you used some other way kindly tell me Or if you can, kindly share you project setting android section image. So that i can see what permissions you used.

I will be very greatfull to you brother :slight_smile:

Really thanks for solution. But i am kinda confuse. I will be thankfull if you give me following information

You are successfully saving game in android 11 using just “Write_External_storage” “Read_External_Storage” permissions???

Or you used “Manage_External_Storage” Permission??

Or you are Requesting Write/Read Permissions in runtime through Blueprint node “Request Permission” ??

If you used some other way kindly tell me Or if you can, kindly share you project setting android section image. So that i can see what permissions you used.

read-only and write-only, Manage_External_Storage gives a lot of powers, and when loading the apk in the play console, Google will require you to explain why you are using this permission

Yeah i have read that MANAGE_EXTERNAL_STORAGE should be use in special case like file manager apps etc.
So i will avoid manage_external_storage. Will only use read/write…i hope it will work

I heard google rejects app if you use Manage_External_Storage. Then how you managed to publish your app with ManagE_Extetnal_Storage?

I was able to get my save game working finally in Android 11.
I needed to enable Use External Storage, Manage_External_Srorage, and added Read and Write permissions. Using Google PAD this now worked for SDK30 / Android 11.

I haven’t published it yet, however it is in open testing on Google play and there haven’t been any notifications or errors after uploading. Per googles own documentation on the new permissions for Android 11 there was no mention of apps not being able to use this functionality.

Sure. Message me on here?! Or support@smidgegames.com

can i get your contact info? whatsapp or email anything?

Brother i have published my game on play store with Write_External_Storage and Read_External_Storage but still Save Games not working in android 11. Kindly guide me im kinda stressed.

Brother i have mailed you… Kindly reply there

Sorry for disturbing you again bro. Iam using ue4.26, target api 30 minimum 23
Ndk api level=android 30
Sdk api= matchndk
Giving write n read permissions
Even after publishing(updating old game app wd these settings) using .aab …iam.still no lt successfull
Iam.not using PAD because my .aab size is less than 150mb

I dont know what to do
Kindly help me…or kindly give me your contact info …so that i can talk u in detail…im really stressed

I submit request to explain why my game needs local saves after adding MANAGE_EXTERNAL_STORAGE.

However, do you know how to use storage access framework that GooglePlay recommends in unreal engine?

Any advice is apprecited.

There clearly is a problem if developers can’t properly test apps on their own phones because things like this refuse to work. I’m making an app for my own use that I have no desire to publish through the play store. I should be able to save data when I need to. Currently I cannot. I’ve been going nuts over 3 days trying every suggestion I can find and nothing allows save data to work. Read/write permission is given but it still won’t create an actual save file.

The fastest way to solve the issue is as follows:

In SaveGameSystem.h

	virtual FString GetSaveGamePath(const TCHAR* Name)
	{
		FString saveDir;
#ifdef USE_ANDROID_FILE
		extern FString GInternalFilePath;
		saveDir = FString::Printf(TEXT("%s/SaveGames/%s.sav"), *GInternalFilePath, Name);
#else
		saveDir = FString::Printf(TEXT("%sSaveGames/%s.sav"), *FPaths::ProjectSavedDir(), Name);
#endif

		UE_LOG(LogTemp, Warning, TEXT("Save game path: %s"), *saveDir);

		return saveDir;
	}

PS: This solution requires no write permission because GInternalFilePath is set with getFilesDir() function call in native side and then set in AndroidJNI.cpp GInternalFilePath = FJavaHelper::FStringFromParam(jenv, internalFilePath);
(Data and file storage overview  |  Android Developers)

4 Likes