Question

Possible Duplicate:
Is there a clock in iOS that can be used that cannot be changed by the user

I know in many iOS games that have tasks that take time (i.e. "10 hours until animal done breeding"), one can go into "Settings" and change the time to speed up the completion of the task. In the game I'm developing, I don't want users to do this, so I'm trying to implement a system to prevent this type of cheating. I've put a lot of thought into this, but can't come up with a solution. Basically, my question is how do I keep track of time without relying on the system clock (which can easily be manipulated) for the purpose of preventing users from cheating?

Was it helpful?

Solution

transforming my comment into an answer.

Instead of relying on a user or device, rely on an external source for providing unbiased time. A time server, your server, etc. If you don't trust....

OTHER TIPS

Instead of "X hours of real-world time", would "Y minutes of in-app time" work for you? You can pause/continue a timer when your app suspends/resumes.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top