private void Start() { inv = FindObjectOfType <Inventory> (); uIMouse = FindObjectOfType <UIMouseControll> (); weapon = FindObjectOfType <Weapon>(); hUDGamePlay = FindObjectOfType <HUDGamePlay>(); icon = transform.GetChild(0).GetComponent <Image> (); }
private void Awake() { if (Instance == null) { Instance = this; } hUDGamePlay = FindObjectOfType <HUDGamePlay> (); waveManager = FindObjectOfType <WaveManager> (); weapon = FindObjectOfType <Weapon> (); playerAnim = GameObject.FindWithTag("Player").GetComponent <Animator> (); hudAnimator = hUDGamePlay.GetComponent <Animator> (); storeManager = FindObjectOfType <StoreManager> (); StartCoroutine(Wave(() => { waveManager.StartWave(); })); Cash = 1000; }