Skip to content
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

Support mouseOut/pointerOut style event when the cursor leaves the game canvas #3080

Open
eonarheim opened this issue May 27, 2024 · 0 comments
Labels
feature Label applied to new feature requests

Comments

@eonarheim
Copy link
Member

Context

It is often useful in games to know when the pointer leaves the game canvas. For example: pausing, deselecting, performing specific game logic.

Proposal

Create a new excalibur pointer event that tracks, perhaps analogous to the actor "exitviewport" and "enterviewport"

Current strategy

engine.canvas.onmouseout = () =>{
    console.log('Strike!')
};
@eonarheim eonarheim added the feature Label applied to new feature requests label May 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Label applied to new feature requests
Projects
None yet
Development

No branches or pull requests

1 participant