Hey,
You could try something like this.
Run a LineTrace and when hit something save hit result as variable (you will need it later). Check class of actor hit, if it’s the right one then create widget, or bring it up on screen if created earlier (is valid check). Set game mode to UI and bring up mouse cursor on the screen. If you want to check more item (classes) do another check of the first branch false.
Rest should be pretty clear with the screenshots if not just ask.




