I'm currently trying to develop an isometric RPG(ish) game which should implement a mouse cursor which is following my mouse movement. Furthermore said cursor should stop at the edge of the "game window". So far this works fine. A small detail which bothers me is the fact that the cursor is stopping, but is still clipping out of my game window. I've now worked out two approaches to solve this problem:
A.) Hard-coded borders which incoporate the cursor size
B.) Use some solution which is provided by the Godot Engine itself
C.) Implement Cursor as a sprite
Now, considering option B.) is there any solution which may be a good fit? I've already looked for a hint inside the documentation. Unfortunatly I couldn't find anything.
Thank you for the advice. However, I'm already using the MouseMode you've mentioned. (In theory) the problem is non-existent because the top-left part of the cursor is stopping at the edge of the game window. The practical problem is that the rest of the cursor is hanging outside of the window
I want to use a confined mouse cursor which stays inside the window completly. Completely means that the cursor and its sprite are inside the game window all the time.
In the MouseMode MouseMode.MOUSEMODECONFINED the pointer of the cursor is stopping at the edge of the game window. However, the sprite "overflows" outside of the game window
Thanks in advance for any help