// Start is called before the first frame update void Start() { simpleShoot = GetComponent <SimpleShoot>(); ovrGrabbable = GetComponent <OVRGrabbable>(); bulletText = GameObject.Find("Label Text").GetComponent <TextMeshProUGUI>(); //bulletText.text = maxNumberOfBullet.ToString(); }
/** * Executes when the character starts shooting at the player instead of moving toward them. * Turns Basic Shoot on so it will shoot at a constant rate. * */ IEnumerator Shooting() { isShooting = true; SimpleShoot mySimpleShoot = GetComponent <SimpleShoot>(); if (mySimpleShoot != null && mySimpleShoot.enabled == false) { mySimpleShoot.enabled = true; } yield return(new WaitForSeconds(timeToShoot)); mySimpleShoot.enabled = false; isShooting = false; yield break; }
// Start is called before the first frame update void Start() { simpleShoot = GetComponent <SimpleShoot>(); //ovrGrabbable = GetComponent<OVRGrabbable>(); }
// Use this for initialization void Start() { simpleShoot = GetComponent <SimpleShoot>(); ovrGrabbale = GetComponent <OVRGrabbable>(); bulletText.text = maxNumberOfBullets.ToString(); }
// Start is called before the first frame update void Start() { simpleShoot = GetComponent <SimpleShoot>(); }
void Start() { shootBehaviour = GetComponent <SimpleShoot>(); grabbable = GetComponent <OVRGrabbable>(); audio = GetComponent <AudioSource>(); }