Offline timer?

Has anyone made a mechanic that can add to a coin count while the game is closed?

For example, the player get 5 coins. Each playthrough a coin gets used. And after 30 minuets the player gains another coin for another attempt. How could I make it so if the player closed the app for an extended amount of time (let's say 4 hours) they could still come back with a fresh coin count (2 coins an hour, 8 coins after 4 hours)?

This would be easy if they just kept the app open 24/7, but thats not an option. My thought is there would need to be an actor to save game.time. Then another actor that will load the previously save game.time and calculate how long it was between the save and load, but where does that come from? What would it look like in GS?

Thanks all.

Comments

Sign In or Register to comment.