// Use this for initialization void Start() { thePlayer = GameObject.FindGameObjectWithTag("Player"); if (thePlayer == null) { Debug.LogError("thePlayer not found."); } thePlayerStatus = thePlayer.GetComponent <PlayerStatus>(); if (thePlayerStatus == null) { Debug.LogError("thePlayerStatus not found."); } theBoss = GameObject.FindGameObjectWithTag("Boss"); if (theBoss == null) { Debug.LogError("theBoss not found."); } fsmBoss = theBoss.GetComponent <FSMBoss>(); if (fsmBoss == null) { Debug.Log("fsmBoss not found."); } }
void Awake() { fsm = FindObjectOfType <FSMBoss>(); if (fsm == null) { Debug.LogError("fsm not found"); } }
void Awake() { fsmBoss = FindObjectOfType <FSMBoss>(); if (fsmBoss == null) { Debug.LogError("bossController not found"); } }
void Awake() { ballExplosion = gameObject.transform.Find("BallExplosion").gameObject; ball = gameObject.transform.Find("Ball").gameObject; smoke = gameObject.transform.Find("Ball/Smoke").gameObject; if (GameObject.FindGameObjectWithTag("Boss")) { fsmBoss = GameObject.FindGameObjectWithTag("Boss").GetComponent <FSMBoss>(); timeToGenerate = fsmBoss.preBallAttackDuration; } particlesManager = GameObject.Find("ParticlesManager"); }
void Awake() { Scene scene = SceneManager.GetActiveScene(); if (scene.name == "Dungeon Boss") { fsmBoss = GameObject.FindGameObjectWithTag("Boss").GetComponent <FSMBoss>(); bossStats = GameObject.FindGameObjectWithTag("Boss").GetComponent <EnemyStats>(); } contains = new List <GameObject>(); tornadoBodyScript = tornadoBodyGO.GetComponent <TornadoBody>(); tornadoBodyPS = tornadoBodyGO.GetComponent <ParticleSystem>(); tornadoBasePS = tornadoBaseGO.GetComponent <ParticleSystem>(); }
void Awake() { fsmBoss = FindObjectOfType <FSMBoss>(); if (fsmBoss == null) { Debug.LogError("Error: fsmBoss not found"); } movingDoors = GameObject.FindGameObjectsWithTag("MovingDoor"); if (movingDoors.Length == 0) { Debug.Log("Error : movingDoor not found."); } sightRange = GetComponent <BoxCollider>(); //Collider starting size sightRange.size = new Vector3(24.0f, 7.0f, 5.0f); }
void Awake() { Scene scene = SceneManager.GetActiveScene(); if (scene.name == "Dungeon Boss") { fsmBoss = GameObject.FindGameObjectWithTag("Boss").GetComponent <FSMBoss>(); bossStats = GameObject.FindGameObjectWithTag("Boss").GetComponent <BossStats>(); } contains = new List <GameObject>(); tornadoCirclesPS = tornadoCircleGO.GetComponent <ParticleSystem>(); foggyBasePS = foggyBaseGO.GetComponent <ParticleSystem>(); smallFragmentsPS = smallFragmentsGO.GetComponent <ParticleSystem>(); player = GameObject.FindGameObjectWithTag("Player"); playerStatus = player.GetComponent <PlayerStatus>(); tornadoEyeTr = transform.FindChild("TornadoEye"); tornadoCircles = new ParticleSystem.Particle[tornadoCirclesPS.main.maxParticles]; }
// Use this for initialization void Awake() { fsmBoss = FindObjectOfType <FSMBoss>(); }