hannyajin Posted October 10, 2014 Share Posted October 10, 2014 Hello, How to capture touchmoves Globally on the whole stage like stage.mousemove does for desktops? stage.touchmove doesn't seem to do anything and sprite specific touchmoves only trigger if the touchmove was started inside the sprite while still continuing to register outside of it as long as you don't let go. Thanks. Quote Link to comment Share on other sites More sharing options...
Tweeper Posted November 6, 2014 Share Posted November 6, 2014 Got it working like this:canvas.addEventListener("touchmove", onTouchmove, true);function onTouchmove(e) {x = e.touches[0].clientX / myCanvasScale;y = e.touches[0].clientY / myCanvasScale;}But indeed, it would be nice if this would be an event directly on the stage, with the same global.x and global.y and the same scaling.Anyhow: pixijs is the most fun framework to toy around with! Instant happiness everytime! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.