You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, i am begining developing simple game in flame. And i have no idea how to save game state in situation when application goes to background.
In current state, after moving back to foreground, is the game restarted.
Thank you for your reply and have a nice day
PS. Sorry for my English, my language skill is very poor :-)
The text was updated successfully, but these errors were encountered:
Hello @aleslanik2 I don't if I quite understand what you are asking, but when the app is moved to background, it is not killed (at least on Android, I'm not sure about iOs) you could keep your state on memory and use the lifecycleStateChange method to resume the game from your state.
Another option is to save your state on the shared preferences of the device, flame doesn't provide any solution for this out of the box, but I can recommend this lib in order to achieve that.
Hope this helped, any other question, feel free to ask
Hi, i am begining developing simple game in flame. And i have no idea how to save game state in situation when application goes to background.
In current state, after moving back to foreground, is the game restarted.
Thank you for your reply and have a nice day
PS. Sorry for my English, my language skill is very poor :-)
The text was updated successfully, but these errors were encountered: