1

I'm developing a mini game that has an Energy System. The maximum energy a player can have at one time is 5. Whenever you execute an action, 1 energy gets deducted. The energy will be replenished by 1 after every 10 minutes.

I can see the easiest way out of this is by querying an external server which will return me a proper time. The problem is that this game is designed for offline play, and it's not meant to query a server every time I launch.

I'm not sure how to go about from here. How should I prevent a fast forward time cheat so that players will not get energy easily?

Joel Tay
  • 83
  • 1
  • 9
  • 3
    While not an easy-to-find duplicate, this Q&A answers your question: [Getting iOS system uptime, that doesn't pause when asleep](http://stackoverflow.com/questions/12488481/getting-ios-system-uptime-that-doesnt-pause-when-asleep) – lnafziger Oct 16 '13 at 03:33
  • The solution is good enough for me! Thank you! :) Btw, how do I answer this question/ accept answer since it's in the comment? – Joel Tay Oct 16 '13 at 13:30
  • Well, you don't since I didn't answer it. Hopefully (especially since you agree) other people will mark this as a duplicate, and people looking to do this in the future will get re-directed over to that question/answer. The best thing to do is to leave this question here, and go to the linked question and make sure that you vote up both the question and the answer that helped you! – lnafziger Oct 16 '13 at 19:37

0 Answers0