Table of Contents
Warning
The DistanceToNearstSurface function has a known issue in UE5.3, resulting in a blocky output. This bug will be addressed and fixed in UE5.4. For more details, refer to https://issues.unrealengine.com/issue/UE-150397.
End Result

Shader Graph

Settings
Please remember to deactivate the “Affect Distance Field Lighting” option for objects where you do not want the distance field effect to be generated, such as the slime itself.

Variations
By masking the VertexNormalWS with RG, it restricts the deformation of the slime in the z-direction, causing it to deform only when it comes into close contact with the surface. This prevents protrusions as if the slime is being attracted to the surface.


Reference and Credit PrismaticaDev: https://www.youtube.com/watch?v=yzvq8aonDYQ