Skip to content
This repository has been archived by the owner on Jan 19, 2023. It is now read-only.

Latest commit

 

History

History
11 lines (8 loc) · 394 Bytes

README.md

File metadata and controls

11 lines (8 loc) · 394 Bytes

Mouse dragging the ViewPort/Camera

I'm trying to make it so I can get the effect from most RTS games, pressing the left button on my mouse to "grab" the world and dragging the mouse to pan the view. But it seems the Camera2D does not get sent any unhandled events? Did I make a mistake?

Solution

A ColorRect is a Control object as well, so we need to make sure it ignores mouse events.