here send the files in here rfstickrungamer@gmail.com
tatiangMember, Sous Chef, PRO, Senior Sous-ChefPosts: 11,949
To answer your question, you'll need to change the value of an attribute (a boolean) when the player presses the button AND a certain amount of time has elapsed. Here's a rough idea of how to do it:
Create a real attribute called self.touchTime and set it to some huge number (e.g. 999999).
When touch is pressed Change Attribute self.touchTime to self.Time When self.Time > self.TouchTime+2 [behavior to make the player run] Otherwise Change Attribute self.touchTime to self.Time+999999
The +2 forces the player to hold the button down for 2 seconds. You could make it 1 second or 0.6 seconds or whatever you prefer.
Comments
Please help us lol
Create a real attribute called self.touchTime and set it to some huge number (e.g. 999999).
When touch is pressed
Change Attribute self.touchTime to self.Time
When self.Time > self.TouchTime+2
[behavior to make the player run]
Otherwise
Change Attribute self.touchTime to self.Time+999999
The +2 forces the player to hold the button down for 2 seconds. You could make it 1 second or 0.6 seconds or whatever you prefer.
New to GameSalad? (FAQs) | Tutorials | Templates | Greenleaf Games | Educator & Certified GameSalad User