toggle menu
Categories
Discussions
Dashboard
Sign In
·
Register
Sign In
·
Register
Categories
Discussions
Dashboard
Sign In
·
Register
×
Home
›
GameSalad 101
›
Working with GS (Mac)
How To Make A Timer Pause
TheDmanTravers
Member
Posts:
22
December 2010
edited November -1
in
Working with GS (Mac)
Hi Im Making A Game Were You Hold Down For As Long As YOU CAN So Im Using A Timer And When I Let Go I Want The Timer To Stop
Comments
MotherHoose
Member
Posts:
2,456
December 2010
Do you just need to know the duration of the Hold Down?
if so
gameAttribute real type named startTime
gameAttribute real type named endTime
on Actor to be held down
[Rule] when touch is pressed
--changeAttribute startTime = game.Time
[Rule] when touch is pressed
--changeAttribute endTime = game.Time
wherever you want to display the duration
Display Text [expression] game.endTime - game.startTime
MH
Sign In
or
Register
to comment.
Comments
if so
gameAttribute real type named startTime
gameAttribute real type named endTime
on Actor to be held down
[Rule] when touch is pressed
--changeAttribute startTime = game.Time
[Rule] when touch is pressed
--changeAttribute endTime = game.Time
wherever you want to display the duration
Display Text [expression] game.endTime - game.startTime
MH