This sample project shows how to convert from screen to world coordinates while using a camera component.
The project also shows how the screen_to_world() function can be used to anchor game objects to the corners of the screen regardless of screen resolution and aspect ratio.
Graphics by Kenney.nl