Sign in to follow this  
JECKL

PIXI Interaction Touch

Recommended Posts

Hi! I am a Korean developer.
I'm making my game engine!

But I have a little problem.

The problem is that I am getting a mouse position using 'render.plugins.interaction.mouse.global'

But on the mobile, the coordinates are returned {x:-999999,y:-9999999}!

So I'm going to create a dummy sprite and use 'pointermove' to get a mouse position, but 'pointermove' doesn't set a position as soon as I click.

That's why I'm trying to use 'pointerdown' and other game objects get in the way!

What should I do?

 

Share this post


Link to post
Share on other sites

I think you'll have to look inside "sprite._trackedPointers". 

https://github.com/pixijs/pixi.js/blob/dev/packages/interaction/src/interactiveTarget.js#L105

Just stop inside an event with a breakpoint and look whats inside "_trackedPointers".

I'm not the best person to talk about interaction, I'm calling @themoonrat :)

Share this post


Link to post
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...
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.