I’ve tried to add a GameObject so I can call it’s mesh but I get this error
“Mesh is not a member of UnityEngine.GameObject”
Here’s the variable declaration
var Water: GameObject;
Here’s the line where I call it
var waterHeight = GetHeightAtLocation(wpos.x,wpos.z,200,200,200,200,Water.Mesh);
When I had Water as a Mesh type I couldn’t add the mesh in my Hierarchy to the inputs, only items in my things on my project tab. I need to send the mesh to the script so I can get it’s height values as it deforms.
How do I do this?