limit to one touch vs multi?

LeanneLeanne Member Posts: 168
edited May 2012 in Working with GS (Mac)
my game is done (!)...well...except for a huge problem that i can't figure out how to solve. each level has an increasing number of puzzles to choose from. when a level is unlocked, all puzzles in the level are unlocked so that the user can decide which puzzle to do first. the user sees a screen with a "badge" representing each puzzle. Tap on a badge, get to the puzzle. BUT if the user taps on two badges at the same time, both puzzles get launched and it is all royally messed up! So, the question is...
Can I somehow restrict the device from only registering one tap vs. multiple taps when an certain actor is present?

Answers

  • LeanneLeanne Member Posts: 168
    try if touch is pressed and device.touch.count = 0

    see if that works

    cheers

    tried, but it didn't work. I think because at the time of touching each "badge," the touch count is 0, because the touches are happening at the same time.
  • LeanneLeanne Member Posts: 168
    you are so helpful. thank you. before you posted that i actually went with the first suggestion that added a manual change attribute device.touch.count to 1, if touched and device.touch.count=0. not sure why, but it worked! now to apply it throughout and get this project out!
  • eoineoin Member, PRO Posts: 36
    I can confirm that the second method is working best for me.
    faster to code into 100 items
  • eoineoin Member, PRO Posts: 36
    nope it doesn't work on the ipad adhoc version, the first method must be the one!
  • eoineoin Member, PRO Posts: 36
    neither of these things work if you are constraining the X+Y mouse positions for a drag drop game. As soon as you change the boolean to false it stops dragging the item.

    I need a drag and drop game where you can only drag one item (at any one time) ,
    out of a possible 5 items.

    Nightmare trying to get something the works solid.
  • -Timo--Timo- Member Posts: 2,313
    make an actor and constrain it to touch1 X and Y. make another and constrain it with touch2 X and Y. dont know if this will work with your problem but this is a way to know if its touch 1 or 2.
  • eoineoin Member, PRO Posts: 36
    I agree that would be a really nice way to do it, but imagine how hard that is going to be to scale up for a game with hundreds of dragable items.
  • eoineoin Member, PRO Posts: 36
    I need Drag Exclusivity
  • -Timo--Timo- Member Posts: 2,313
    what is your problem? what do you need to do? do you want to move any actor when pressing with any touch? (touch1/ 2/ 3/ 4/ 5/ etc)
  • eoineoin Member, PRO Posts: 36
    5 actors with drag ability are loaded onto screen , when one is picked up via touch1,
    the others become unresponsive to touch. - This is what i need, is it possible in GS?

    Multi touch, drag, constrain
  • eoineoin Member, PRO Posts: 36
    dont want the user to be able to have access to a touch 2-5
Sign In or Register to comment.