Hi. I am trying to access another object’s component (a script that has the name “spawn”).
function Start(){
var player : MonoScript;
player = GameObject.Find("Player").GetComponent(Spawn);
}
But when I try, I get this error
“Cannot convert ‘Spawn’ to ‘UnityEditor.MonoScript’.”. What is wrong? Thanks.