-
-
Notifications
You must be signed in to change notification settings - Fork 169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mouse edge distance fix #373
Mouse edge distance fix #373
Conversation
resolve issues using distance or bottom and right.
@davidfig Anything I need to do in order to get this looked over? Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Totally need this feature in <3 |
👀 🙏 👀 |
@davidfig I would also love to see this in! I will build a workaround now (reinitialize the plugin on resize with overwriting worldScreen* in viewport) |
@AjayKoenigArcurve @kurtwaldowski-echelon : There is a nice workaround (worldScreenX = screenX * scale): // workaround until https://github.com/davidfig/pixi-viewport/pull/373 is merged
const oldScale = {x: viewport.scale.x, y: viewport.scale.y}
viewport.scale = {x: 1, y: 1}
viewport.plugins.get('mouse-edges')?.resize()
viewport.scale = oldScale |
@ribx Thanks for the workaround, I forked but may run with this instead for now! |
Confirmed it works on my end as well, thanks for this for the time being. |
Thanks! |
The wrong variable was used, causing strange behavior when using MouseEdge with distance, for Right and Bottom.
This issue was mentioned here: #263
@davidfig