How can I make a moving opacity mask (not a sphere)?

Hi, I have a material that I would like to gradually mask the opacity from top to bottom. Following a short [tutorial][1] by one of Epic’s a technical artists I have discovered the awesome ‘SphereMask’ which, with some fiddling, I am now able to edit it’s radius, hardness and world position.

This is very close to what I’m looking for, except I need a square/cube version so that the opacity mask is a flat straight line as a posed to a rounded edge. After searching high and low I cannot find a substitute that I can control the world position of… is there one? or can someone offer a better suggestion?

Essentially what I’m trying to do is; as the player loses health, the health bar is gradually opacity masked until it is all gone (revealing the base UI behind the sprite).

This is how my current material looks:

loud trumpets

Huzzar! I have managed to implement the following system to achieve the exact result needed:

Now I just need to work out how to reference the value (currently 0.4) in my blueprint :slight_smile: