I’m trying to setup a camera system where the player drags themselves around the world (similar to games like Black and White). I can use GetMousePosition(lastMouseDragX, lastMouseDragY); when they click and find the difference on tick to move the camera, however this doesn’t work like grabbing a piece of the world and dragging around.
What I would like is the mouse cursor to stay in the same position relative to the world while the camera moves around. This is a can be a bit more complex than getting mouse position because it depends on how far the object they clicked on in the world is from the camera and possibly resolutions/fov settings.
Anyone have some advice on how to accomplish this?