If a button is clicked while it is not enabled - it runs the event as soon as it is enabled

sokarokasokaroka Member Posts: 9
edited May 2013 in Working with GS (Mac)
Here's the screen.
http://puu.sh/2Y0or.jpg

The three objects highlighted on the game screen are buttons.
When you click the play button all the hills scroll across to be on screen.
When you click play a timer also activates.
After a 3 second wait, the variable "buttons" = 1 from 0.

Then down the bottom you can see my logic for the buttons.
The buttons are only supposed to change the scene if play is 1.
However, if you click on screen where a button is before clicking play, then you click play, the scene changes as soon as buttons changes to 1.

In my head this is not how logic works.
Does this mean if you click a button and it checks false, so it does not change scene, it loops CONTINUOUSLY FOREVER until it is true, and then runs the following events?

Is this a bug orrr.....what can I do to fix it?

Comments

  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408
    Try changing it to touch is pressed
  • sokarokasokaroka Member Posts: 9
    That worked, thanks!

    Was there something wrong with my logic, or is it a bug?
  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408
    when touch is released they all trigger for some reason, i ran into it with my last project. I had to switch to pressed to make sure it worked.
  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    When you use touch is released it's like turning on a switch and leving it on. Touch is pressed is momentary.
Sign In or Register to comment.