Ok I am going crazy how come none of these work? I am trying to make a the GameObject prefab to set to a prefab that I want. So I can later place that block.
prefab = (GameObject)Resources.Load(“Objects/Blocks/Dirt”) as GameObject;
prefab = (GameObject)GameObject.Instantiate((GameObject)Resources.Load(“Objects/Blocks/Snow”));
prefab = Instantiate(Resources.Load(“Resources/Blocks/Dirt”, typeof(GameObject))) as GameObject;
All return null!
After doing this I then do Instantiate(prefab, G, Quaternion.identity); which works fine but only does it when I drag object to prefab in editor. This can’t happen since I need to switch the prefab to other types of blocks.