コード例 #1
0
 private void Shoot()
 {
     if (Input.GetButtonDown("Fire1"))
     {
         shooter.ContinueFiring(true);
         shootingCoroutine = StartCoroutine(shooter.Fire());
     }
     if (Input.GetButtonUp("Fire1"))
     {
         shooter.ContinueFiring(false);
         StopCoroutine(shootingCoroutine);
     }
 }