How do i make a custom cursor to be on top of a UMG Widget?

Another way to create cursor, you can :

1.Create a new widget called Mouse Cursor(or anything else).

2.Put your cursor image into Root Canvas, define a size to it

3.Align image to center of canvas (Anchor ->Center, Pivot → X=0.5 Y=0.5, Position= 0,0 )

4.Call “Create Widget” node & “Add To Viewport” node once in other BP such as HUD BP or Character BP when game start.

5.Don’t forget to set ZOrder in AddToViewport node to a large number that always greater than your amount of widgets exist at same time.

6.Save this widget reference to a variable.

7.Set widget’s position to mouse position use “Set Position In Viewport” in Event Tick.

Advantages:

You don’t need to create cursor image in every widget. (Less work and easy to modify)

You can use HUD BP to set cursor position, apply HUD class to Game Mode so that you could assign custom cursor to specific level.