Touch section issues

reddotincreddotinc Member Posts: 653
edited November -1 in Working with GS (Mac)
Hi guys,

I'm working on a project at the moment that has two touch sections, one for the left side of the screen, and one for the right. I have it changing an integer when the touch is pressed, and changing back when released. This works great.

However, when I touch in the section and drag my finger out of that section, the integer does not change back until another touch is released in that section, and likewise for the right section.

If I have the left section touched and touch the right section, then the left section's touch is affected which i do not want.

Any ideas on how best to integrate this?

Thanks in advance :)

Comments

  • UtopianGamesUtopianGames Member Posts: 5,692
    Could you have 2 invisible actors for each half? for eg if your doing landscape 480x320 have the 2 actors 240x320.

    Darren.
  • JackBQuickJackBQuick Member Posts: 524
    How about using Actor receives event: touch is inside? That way, if touch is inside, it does one thing; if outside, another.
  • reddotincreddotinc Member Posts: 653
    Thats what I do have, two transparent PNGs that are the width and height of my choosing.

    I tried using touch is inside, but once there is another touch (e.g. if i hold the left and touch the right) the left touch gets disabled.

    It seems like I'm missing some configuration for what to do if there are multiple touches?
  • JackBQuickJackBQuick Member Posts: 524
    There are multiple touches. Choose Attribute in your rule, and then Devices followed by Touches.

    I have not used multiple touches before so this is where my knowledge ends.

    Maybe you have to use Touch1.X? I also see there is a Touch.Count function. Maybe someone else in the forum with experience in these can chime in?
  • reddotincreddotinc Member Posts: 653
    I have this set up in another section for firing, but not for touches.

    I want to be able to set as effectively a button, so as long as the touch is on the button and held down, then it is active, no matter how many touches occur elsewhere
  • JackBQuickJackBQuick Member Posts: 524
    Have you tried a double rule using touch is pressed and touch is inside?
  • reddotincreddotinc Member Posts: 653
    Yep,

    When i have that, if I have touch 1 holding left, then press outside it, it removes the integer from the left touch
  • Rob2Rob2 Member Posts: 2,402
    GS is very good at dealing with touches. GS will log and maintain positions and status of up to 5 touches. Touch identity is maintained through multiple touches. There is a great free GS app called idevices by vmlweb http://vmlweb.co.uk/Main/Home.html it will show you what is possible.
  • JackBQuickJackBQuick Member Posts: 524
    @Rob2 - Thanks for the tip about iDevices!

    There is also a How To on How do I make use of multi-touch. (You have to scroll down a bit.)

    I think you might have to make use of Touch.Count.
  • reddotincreddotinc Member Posts: 653
    That looks like a good little application, however all I effectively want to do is allow touch touch "actors" to work independently of each other, where the left allows touches and there will be times when it will be constantly pressed, and the right will only ever be touched singly.
Sign In or Register to comment.