void Start() { player = FindObjectOfType <PlayerMains>(); }
// Use this for initialization void Start() { player = Player.FindObjectOfType <PlayerMains>(); text.text = (player.Ammo).ToString() + " / " + (player.ammo_cap).ToString(); }
//Enemy AI void Awake() { instance = this; }