ShaderGraph Position Node Problem

I’ve been working on a water shader and I’m trying to make a point object match the Y position of the water waves at a given point/sample. The way the water shader works is with vertex displacement. I use the Position node with the “World” option to sample all the vertices of the plane.

4658345--437867--Water.gif

The red object is a separate GameObject that samples a point (X,Z) with the same parameters as the water shader to get the correct Y position every frame.

Now this all works fine until I scale or move the water plane object in my scene.

4658345--437870--Water Broken.gif

I thought World Position node represented a vertex position in the world after all the transformations have been done to it from the “parented” object, but what I’m seeing is the shader acts as if there was no transform done on it so it calculates all the waves and then the transform is applied for rendering. Is there a way I can get a “World Position after transforms” in ShaderGraph?

Found the solution. I just noticed there’s an Object node with a Position + Scale. You can offset those values to the world position node to get the proper values.

How do you offset it? I’ve seen that technique mentioned several times but it doesnt seem to work for me. HDRP 2020.3