//always called before start function void Awake() { saber = GameObject.FindGameObjectWithTag("Saber"); saberSplit = saber.GetComponent <SaberSplit>(); //connects to script with info about saber movements //head = GameObject.FindGameObjectWithTag("MainCamera"); head = GameObject.FindGameObjectWithTag("MainCamera"); }
//always called before start function void Awake() { saber = GameObject.FindGameObjectWithTag("Saber"); saberSplit = saber.GetComponent <SaberSplit>(); //connects to script with info about saber movements world = GameObject.FindGameObjectWithTag("world"); lightScript = world.GetComponent <Lighting>(); rend = GetComponent <Renderer>(); head = GameObject.FindGameObjectWithTag("MainCamera"); }
//always called before start function void Awake() { saber = GameObject.FindGameObjectWithTag("Saber"); saberSplit = saber.GetComponent <SaberSplit>(); //connects to script with info about saber movements world = GameObject.FindGameObjectWithTag("world"); lightScript = world.GetComponent <Lighting>(); //head = GameObject.FindGameObjectWithTag("MainCamera"); head = GameObject.FindGameObjectWithTag("MainCamera"); spawn = GameObject.Find("BlockSpawner"); spawnScript = spawn.GetComponent <BlockSpawner>(); blockHit = false; woosh = GameObject.FindGameObjectWithTag("woosh").GetComponent <AudioSource>(); woosh.volume = 0.2f; }