Indie Dev

Hello Guest!. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, sell your games, upload content, as well as connect with other members through your own private inbox!

RPG Maker MV: Android update deletes savegames!

Hello everyone,

I have a problem with my RPG MV game in android, with the savegames.

When you install the apk on your android device, all the savegames will be deleted when you uninstall the game. Same thing, when you have the game in Google Play Store and update it, because the whole game is deleted and will be installed after that.

Hope you understand, that this is a really big problem. RPG Maker MV cannot be used with this problem, because you have to update the game sometimes, there is no other way like everyone knows. An RPG Game is very complex and it is nearly impossible if not impossible to make it completely free of bug on the first run.

So when all the savegames of the users are deleted when you upload an update, it's not possible to use the game in reality and then the whole exportation to Android makes no sense.

I hope you see my point. It's really frustrating, because everything works fine and you can do everything you want... and then the wohle thing is lost because of such a laughable issue!?

---------

So the question is: Is there anyone who can help us with this problem?

I was even not able to find the install destination folder on the Android device. Didn't find it in the hidden files. But however, even if i would find it, i'm very sure, that there will be no savefile available like in your pc game of RPG Maker MV.

I think the solution must be very easy, but if the problem persists, RPG Maker MV is actually not usable on Android devices!

Thanks a lot for everyone who reads this and tries to help.
 

Xilefian

Adventurer
Xy$
0.00
Which method did you use to produce your Android app? There's several methods and knowing which one you used will help solve the problem.

Android/iOS/Web deployments (basically any deployment that's not a node.js client) use Web storage for saving data, it does not use file-system, so no save files are created, it's all stored in an internal database.

This internal database should survive app updates, but it's not perfect. It's as reliable as saving data on any web-deployed game.

I remember one person using the MV Android Client had a similar issue to what you have, however it turns out they had were changing their RPG Maker MV game title between versions - which breaks the web-storage feature as it is the RPG Maker MV game title that is used to save data. Make sure you're not renaming your game for each version! (My Game - v1.0, My Game - v1.2, etc).

-----

With the MV Android Client, save data definitely works fine because it's part of my standard testing procedure. My device has save files for both WebView and Crosswalk modes and I load those up each time I update the client - it has successfully worked every time, so far.

Web Storage isn't perfect, I'm very aware of this, but to use the Node file-system requires a full implementation of node.js, which I'm not prepared to do for the MV Android Client until someone funds such a massive endeavour. I can hack in file-system support easily, but that will end up breaking a lot of correctly-written Plugins, which is a bad thing (the only Plugins that shouldn't work are badly written ones).
 
@ Xilefian

Thank you for your helpful answer.


Methods:

I use two methods to generate the apk, but I just tried to save and update aso. with the first method.


This first method is by using the Altimit MV Android Client and Webview and integrate it into Android Studio 3.x. It is the method, you explained in another topic (thank you also for that good explanation!).

The second method, which I didn’t try the saving issue with so far is by using cordova and node.js.


I didn’t know, that keeping the save files is basically working. I thought that is a problem everyone has, because RMMV is not prepared well for Android.


I also didn’t know, that the save file is generally deployed in the web. Because in the pc output version you can see the save file in the folder.


Some questions:

My question in this point is, where is RMMV saving the file in the web? And does this also mean, that it is not possible to save or load a file on an android device if you are not connected to the internet?


(If that’s the case, then I think the same method is used when you choose the browser output version. Because I am not used to the browser version so far and I thought about this also, asking myself, if someone plays the browser game, where will the save file be deployed, on his computer? Or somewhere in the net? And where exactly? And does it mean you need an internet connection for saving and loading?).


Also a question according to what you said about node.js: You mean, if I generate the apk by using node.js, then the save file will be on the android device itself and not in the web? And maybe in another folder externally, so that the file is not deleted when I update the app?

No renaming:

As for renaming, I didn’t rename the app, because I tried to upload it in the Play Store and a renamed update apk is not accepted, because the update process cannot deal with it, if it’s renamed. So it was every time the same name.

Once again thank you for your useful informations...
 
Strange. Now it's working. Same method, same apk. With the mv web client, like you said.

Could it be, that there was an error just when i tried it?!

If you just could answer the other questions in my last reply, that would be great to understand the whole thing better.

From what you said, I think the saving process should also work with VN Maker on an update, is that right? Because I generate the apk with node.js for VN Maker.

And I think I misunderstood you before, according to the web saving, right? Think you meant something else. Because the saving and loading process is working without problems, with internet con. and without, so it can not be like I understood, or is he saving the file afterwards in the web?

Thank you a lot for your help and also for the other topic about generating the apk with the web client...
 

Xilefian

Adventurer
Xy$
0.00
WebStorage does not need an internet connection, it's just a database table stored on your local web browser, so when you save your game it writes the "files" to a database, rather than making actual folders and files on the phone.

If you are able to use Node.JS to deploy then you'll have access to the file system of Node.JS, which will create real save files and folders on the device somewhere. If this is the case, then you can re-write the save system on Android as a new Plugin.

If you're using Cordova specifically then you may want to look into the Cordova flie system Plugin: https://github.com/apache/cordova-plugin-file - you'll need to re-write the save system on Android as a new Plugin for this too.

I said renaming the game title, not the app. Don't rename the RPG Maker MV project in the RPG Maker MV editor - this name is what WebStorage uses to write its database entries. The Play Store allows app renames, what it doesn't allow is app id changes.

---

What's worrying is that this works for most people, but not for everyone. The only thing I've seen so far that causes save files to be lost is renaming the RPG Maker MV game name in the editor, any other reasons for it to happen are a mystery.

I've been detailing some plans with @doranikofu for creating an Android API for real save-files on Android, who is having an issue with WebStorage limitations in their project: https://rpgmakermv.co/threads/quota-exceeded-error-for-android-deployment.8305/#post-47248
There's some performance issues to solve and the API needs completing, but once it is ready I can give you a Plugin and a link to the updated code and we can see if that helps save files. The Plugin would delete all the old save files once updated, as it will use a completely new save system.

---

EDIT: Your reply just popped up for me. It is strange that it is working for you now. Did you update the MV Android Client? I did change some database stuff not too long ago, that could have reset the database if you updated the Android project.
 
Last edited:
Thank you for these infos. I updatet the MV Client before, i mean, also when it didn't work...

I repeated the update and saving process and everything seems to work fine so far. Don't know what the problem was, maybe an error when generating or updating the app, maybe a mistake from my side?! Don't know. However it seems to be ok now.

Yes, understood what you meant according to the renaming. I did'nt rename the game title.

With cordova the update and savings are also working, from what I saw until now.

Thanks a lot again for your helpful answers...
 
Top