Touch is released issue

simo103simo103 Member, PRO Posts: 1,331
edited November -1 in Working with GS (Mac)
I have some behaviors triggered by the 'Touch is released' rule. However when I reset the scene if someone fails to complete the task some of those behaviors trigger again.

I'm guessing that 'Touch is released' is still true. Anyone know anything about this and what I might do?

Comments

  • POMPOM Member Posts: 2,599
    @simo103
    Ok here is an idea i hope it will work for you :

    create an attribute - self.IcanDETECTrelease - boolean- set to true
    put the "release rule inside a rule that says :

    when IcanDETECTrelease is true

    if touch is released
    (do something)
    change IcanDETECTrelease to false.
    ____________________

    now make another rule that say:

    when touch is pressed
    change IcanDETECTrelease to true
    _______________________-

    so basically what we are doing here is letting the actor detect the release only if first it was pressed ,

    let me know if it worked fo you

    Roy.
  • simo103simo103 Member, PRO Posts: 1,331
    thanks Roy .. I see the logic and it looks good. Will try it out now and will post afterwards.
  • POMPOM Member Posts: 2,599
    sure , we will figure out something if this won't work

    by the way i just posted promos for my game you can grab one ;)

    http://gamesalad.com/forums/topic.php?id=15511&replies=2#post-118351

    Roy.
  • simo103simo103 Member, PRO Posts: 1,331
    Hi Roy,

    your code suggestion worked perfectly thanks. Also I purchased (since I had some left from xmas iTune gift cards) and did a review in the Cda app store.
  • StormyStudioStormyStudio United KingdomMember Posts: 3,989
    seems a shame that it needs that extra rule...
  • simo103simo103 Member, PRO Posts: 1,331
    yeah stormy agreed .. I have the actor in my HUD so its released status gets reused quite a bit .... would have been nice if it automatically did not register as released after any of the behaviors within were complete.
Sign In or Register to comment.