Simultaneous keys on mobil

Jim Lambert jiml at
Sun Dec 15 16:23:34 EST 2013

BillV wrote:
> I have a iOS game where I have 3 buttons. The user can press any one of them by itself, two of them together, or all three together to register the correct answer. I how do I tell simultaneous button presses from multiple buttons?

Try this in a button script then set that button as the behavior for your 3 touchable buttons.
gTouchedControls will contain the current state of each button. 

Jim Lambert

global gTouchedControls

on touchStart tID 
   hilite me
   put true into gTouchedControls[the short name of me]
end touchStart

on touchEnd tid
   unhilite me
   put false into gTouchedControls[the short name of me]
end touchEnd

More information about the Use-livecode mailing list