Quantcast
Channel: Questions in topic: "loadassetatpath"
Viewing all articles
Browse latest Browse all 62

Loading texture2d by script null instance

$
0
0
Im trying to load a texture2d with c# at Start() I've seen several instances about using Resources.Load but i wasn't able to load it because i keep getting this message that the texture has to be instantiated? NullReferenceException: Object reference not set to an instance of an object this is how im loading private Texture2D gameTitleTxt; void Start() { gameTitleTxt = (Texture2D)Resources.Load("Textures/Gui/menu_design"); } what am I doing wrong?

Viewing all articles
Browse latest Browse all 62

Trending Articles



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