// Update is called once per frame void Update() { if (!static_information.isPaused) { if (Input.GetMouseButtonDown(0)) { GameObject.Find("Boss").GetComponent <bossAI>().hit(damage: 1); } if (Input.GetMouseButtonDown(3)) { bossAI clone = (bossAI)Instantiate(Boss, transform.position, transform.rotation); } } }
// Use this for initialization void Start() { //Reference to boss is used to change speed as fight goes on Boss = GameObject.Find("Boss").GetComponent <bossAI>(); }
void Start() { //Reference to boss is used to know if fight is over Boss = GameObject.Find("Boss").GetComponent <bossAI>(); }