Jump to content

Picking a mesh is not registering on iOS


FbFGlobal_Dev
 Share

Recommended Posts

Hi Everybody!

So I have some hotspots floating around in z space. Each hotspot isPickable = true and each non pickable mesh isPickable = false. When I test on desktop it runs like a dream, but when I test it on mobile devices, the hotspots don't respond to any touch actions/click.

Babylon version is v 2.5.0

I created a PG. The PG works great on desktop and mobile, but the PG is running version 2.6 alpha

Is this something that was adjusted? Am I missing something? Can I change what version of Babylon being used in the PG so I can have a more accurate test?

 

PG: http://babylonjs-playground.com/#PEJDE#8

Link to comment
Share on other sites

Thanks for the replies! Yup PEP is included, and yes touch-action="none" is implemented. I can get all the camera controls to work on mobile, but the "pick" still isn't working. I'm starting to suspect a non Babylon related issue. If I figure it out I'll let you all know.....The info might be useful to someone out there right? haha

 

Thanks again!

Link to comment
Share on other sites

Hi everyone!

so it turns out I needed to include a 'touchend' event listener as well as a 'click' event listener and remove the following from the "onPointerClick" function:

if (evt.button !== 0) {return;}

PEP is included, but for some reason the touchend events weren't doing their thing (All other touch events appeared to be firing without a problem). I tend to think this is all due to how I'm using the framework with other 3rd party platforms, and there was a conflict.....BUT if anyone else bumps into iOS touch events not being triggered when you have PEP loaded properly AND touch-action="none", give the above a try (it might put a smile on your face)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...