need a countdown timer to a specific date.

SharkawyDevSharkawyDev Member Posts: 225
edited December 2011 in Working with GS (Mac)
hey all,

i need a countdown timer that will access system time and show countdown to a specific date.

anyone has such a thing ?

appreciated.

Cheers

Comments

  • SharkawyDevSharkawyDev Member Posts: 225
    any sous !
  • SharkawyDevSharkawyDev Member Posts: 225
    seriously :D
  • tenrdrmertenrdrmer Member, Sous Chef, Senior Sous-Chef Posts: 9,934
    You have access to the System Date and Time. Its just a matter of some math to determine What the timer needs to start at each time the app runs.
  • SharkawyDevSharkawyDev Member Posts: 225
    edited December 2011
    i already made a timer but i have to set the timer so it start countdown, what i wanna do now is the timer will access system time and will count to the specific date i set and will be default for all users.

    EDIT: also i have a timer that access the system time.
  • MotherHooseMotherHoose Member Posts: 2,456
    edited December 2011
    Try sceneAttributes! (well you could use gameAttributes but I always end-up too many..yuck )

    add these: (all integers...as that is what device Clock uses)
    targetMonth
    targetDay
    dayDifference

    in ActorEditor
    Rule: when (All)
    Attribute: targetMonth = [exp] game.clock.Month
    Attribute: targetDay < game.Clock.Day
    ---ChangeAttribute...[exp] scene.dayDifference To: game.Clock.Day – scene:targetDay

    Rules: when
    Attribute: scene.dayDifference = 0
    ---do this & that
    Otherwise:
    Rule:
    Attribute: scene.dayDifference = 1
    ---do this Count(dayDifference).png or whatever
    and so on...

    MH
  • SharkawyDevSharkawyDev Member Posts: 225
    @MotherHoose, thanks for ur time.

    i think you mean Device.clock.month instead of Game.clock.month and so one right ?
  • MotherHooseMotherHoose Member Posts: 2,456
    edited December 2011
    @a.sharkawy
    well, you do select it as Device>Clock>Day ... but the actual [Exp] in expressionEditor displays: game.Clock.Day
    as do Device>Touch; Mouse; etc.

    why? ... who knows ;)

    MH
Sign In or Register to comment.