How to increase 1 life every 30 minutes of device time even when the app is close?
dj_outlaw2000
Member Posts: 11
i have a game that have 5 lives and every time you lose the level you will lose 1 life, and if the lives is lower that 5 i want it to be increased 1 life every 30 minutes of the DEVICE CLOCK even if the app is open or close until its reaching 5 lives and then stop increasing...
my question is about the device clock how to make a rule like this wither by tables or attributes witch is the easier way...
thanks guys and im waiting for your asap reply coz i search everywhere in youtube and the forums here in gamesalad and never find anything about this toppic...
Comments
anyone help? im stuck on this
Hey dj_outlaw.
Every time you lose a life, SAVE the current time of the device. When you open the device LOAD the saved time and compare this with the current time. Then write a rule. If current time is 30 minutes later than saved time, add life etc.
yes I agree with you and ive done this but I stuck in how to make the rule to compare the old saved time and the new time... is it like this?
rule:
if attribute game.life is < than 5
do:
time:
every device.clock.minute*30 or +30 I don't know
do:
change attribute game.life to game.life +1
or the other way is....
rule:
if attribute game.life is < than 5
do:
save attribute device.clock.minute as savedminutes
then another rule
rule: if All
if attribute game.life is < than 5
if attribute device.clock.minutes*30 or +30 is < than current device.clock.minutes
do:
change attribute game.life to game.life+1
I don't know if this is true but I feel like its wrong and need a little fix
Guys any suggestions? I really need help
http://forums.gamesalad.com/discussion/41709/game-that-runs-in-real-time
Hey dj_outlaw2000
Did you solve this problem, becouse i want to do the exact same thing, just use different time to change lives.
No the problem never been solved... So i change the whole rules of my game
Check out the recent discussions involving @Armelline and resource management while the game is inactive. I have personally tested his system and it works great!
My system is unfortunately not free, but I'll be posting about it later since that kind of thing seems to be tolerate now
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
http://forums.gamesalad.com/discussion/87206/resource-gathering-template-tracks-time-while-game-is-closed-or-inactive#latest
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
As i see you are using multiplayer, could that be changed to adding up lives (0+ something for example)? and how much would this template cost?
Yes, it could easily be used to add lives instead. Anything really.
If you click through to the YouTube, or click on the link in my signature you'll see the more info about purchasing.
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support