Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Detecting Multiple touch?

Author
Message
bigtunacan
9
Years of Service
User Offline
Joined: 24th Jul 2015
Location:
Posted: 22nd Jan 2017 04:57
How can I detect if there is more than one touch happening on a mobile device? I would like to get how many touches as well as the X, Y coordinates of all touches occurring.
Lucas Tiridath
AGK Developer
16
Years of Service
User Offline
Joined: 28th Sep 2008
Location: Kings Langley, UK
Posted: 22nd Jan 2017 06:57
For multitouch, have a look at the raw input commands. Specifically if you want to know how many touches there are, I think the command you're after is GetRawTouchCount(1).

Here's a quick example of how you can iterate the touch inputs and find their positions in screen space.
bigtunacan
9
Years of Service
User Offline
Joined: 24th Jul 2015
Location:
Posted: 22nd Jan 2017 19:30
Thanks!

Login to post a reply

Server time is: 2024-11-24 20:29:16
Your offset time is: 2024-11-24 20:29:16