How do I fix touch in a project

Get help using Construct 2

Post » Wed Apr 05, 2017 1:49 pm

I'm using r243

I've been struggling to get touch working right for a project, it's easy enough for the most part and works fine on a desktop but when I test on a samsung s4, things like touch and drag affect the browser window, refresh if I drag downward and double clicking in the app will cause the browser window to zoom in/out. Whenever I touch the event registers, and will stay 'in touch' until I let go, or, if I drag around the screen without letting go intouch will also end.

But here's the tricky part, I looked at the Space Blaster example, and built and ran it to see if it had the same issues, it does not, it works exactly like it should, drag events on the game window do not affect the browser, and intouch events work continuously, the only thing I noticed was I'd get a little vibration from 'long press' but no other side effects there. I did everything I could to try to make my controls work exactly the same in my main project, with no luck.

The final deal is that I created a bare minimum project to test further, it's just a text field, and a Touch object followed by setting the text field to show where I was touching, that worked flawlessly as well. So I can see that things *should* work just fine, but there seems to be something that can mess things up,
B
9
S
1
Posts: 3
Reputation: 431

Post » Wed Apr 05, 2017 2:44 pm

'Fullscreen in browser' set to 'off' is apparently the culprit, I had changed that setting at some point working on some other issue (I don't recall what anymore, and I don't think the setting made a difference for that issue).
B
9
S
1
Posts: 3
Reputation: 431

Post » Fri Apr 07, 2017 7:18 am

I could be wrong, but it sounds to me that most (if not all) of your issues come from your gamewindow being out of focus.

Touching outside of your gamewindow will make the browser respond to your touches instead of the game.
(tapping the game window at this point should work)
This is also why using a fullscreen in browser setting will resolve the issues.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Fri Apr 07, 2017 5:46 pm

No, I was touching within the game window, I haven't tested my bare bones file to see if changing the full screen setting matters or not but I'll probably do that, I'm just trying to finish up the project before sleeping and it's late already.
B
9
S
1
Posts: 3
Reputation: 431


Return to How do I....?

Who is online

Users browsing this forum: ounound and 16 guests