I’ve been trying to figure out how to reference game object’s in the assets folder for a few days now.
var MedBag = AssetDatabase.LoadAssetAtPath("Assets/Sprites/Items/MedBag.prefab",GameObject);
var AmmoBox = AssetDatabase.LoadAssetAtPath("Assets/Sprites/Items/AmmoBox.prefab",GameObject);
I’ve tried using this code and it works in the editor, but once I make a build it throws an error. So if someone could help me out with this it’d appreciated it