Is it possible to create two materials for the same surface??

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By M4gma
uniform vec3 position;
    
void vertex() {
	UV=UV*uv1_scale.xy+uv1_offset.xy;
	float x = UV.x + position.x;
	
	VERTEX = vec3(VERTEX.x,VERTEX.y + sin(x) * 0.03 ,VERTEX.z);
}

I can’t make this vertex shader work because the shader params are shared among all objects with the same material. I believe the solution is to create the shader at runtime but for better performance I’d like to do this for just this part of the shader.

:bust_in_silhouette: Reply From: Warlaan

If I remember correctly you just need to use “make unique” on the material. Click the drop-down menu next to the material in the inspector to find it.