Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | BorisJohnson |
Do 2d top down game and can not figure out how to attach the sprite to the mouse cursor. In 3D mode I would use raycast to get the cursor position in 3D space, but in 2D it doesn’t work. I tried to use get_viewport().get_mouse_position (), but this does not work correctly. How to do it?