Quantcast
Channel: Answers by "Soviut"
Viewing all articles
Browse latest Browse all 23

Answer by Soviut

$
0
0
My current hack solution is to temporarily create another primitive (plane, cube, whatever) and get the Default-Diffuse material from its sharedMaterial and apply it to my new object. GameObject primitive = GameObject.CreatePrimitive(PrimitiveType.Plane); primitive.active = false; Material diffuse = primitive.GetComponent().sharedMaterial; DestroyImmediate(primitive); // ... go.renderer.sharedMaterial = diffuse;

Viewing all articles
Browse latest Browse all 23

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>