Interactive minimap

I’m creating minimap by this tutorial: Beginner Tutorial - How to make a minimap in Unreal Engine 4 - YouTube.

Please, tell me how can i get mouse position from minimap to world space?

  1. Move cursor to minimap
  2. Trace line from minimap to world

The only way that comes to my mind is this:

  1. get screen position of cursor
  2. calculate offset inside the minimap rectangle
  3. do a line trace from the minimap’s camera using this data (probably needs some time figuring out the correct values here)

How deproject mouse coordinates from minimap?