IEnumerator FireRightWave() { int angle = -90; while (angle != 0) { tempProj = Instantiate(proj, rightCannonPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, angle, 100); angle += 5; yield return(new WaitForSeconds(0.2f)); } yield return(null); }
IEnumerator FireWaves() { tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, 20, 100); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, -20, 100); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownFakeGravity(tempProj, 100); yield return(new WaitForSeconds(0.75f)); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, 10, 100); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, -10, 100); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, 28, 100); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, -28, 100); }
IEnumerator LockWaves() { for (int i = 0; i < 20; i++) { tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, 10, 100); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, -10, 100); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, 30, 100); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, -30, 100); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, 50, 100); tempProj = Instantiate(proj, blasterPos, transform.rotation); StandardFireFunctions.FireDownDegreeOffset(tempProj, -50, 100); yield return(new WaitForSeconds(0.2f)); } }