I am currently toying around with a little rpg sort of game.
I am wanting to update a users energy every X minutes.
I know this is possible with a cron, however i am wanting this to work in real time.
Basically I am wanting a little timer under the energy stat point counting down, as it reaches 0 the energy is updated via 1, and the timer goes back to X minutes and counts down again.
Any ideas what the best way to accomplish this is?
Can the user spoof the timer in anyway by changing the time on their device?
Thanks
I am wanting to update a users energy every X minutes.
I know this is possible with a cron, however i am wanting this to work in real time.
Basically I am wanting a little timer under the energy stat point counting down, as it reaches 0 the energy is updated via 1, and the timer goes back to X minutes and counts down again.
Any ideas what the best way to accomplish this is?
Can the user spoof the timer in anyway by changing the time on their device?
Thanks