예제 #1
0
 public void TurnOff()
 {
     isOn = false;
     AudioFW.StopLoop("Laser");
     // If target isScreamerOnly
     AudioFW.StopLoop("Screamer");
 }
예제 #2
0
    public IEnumerator LoseGame()
    {
        print("You Lose!");
        gameLost = true;
        yield return(new WaitForSeconds(2));

        camAnim.SetTrigger("Lose");
        gameAnim.SetTrigger("Lose");
        AudioFW.Play("LoseGame");
        yield return(new WaitForSeconds(1.5f));

        GameObject expl = Instantiate(explosion, transform.GetChild(0).transform.position, explosion.transform.rotation);

        transform.GetChild(0).gameObject.SetActive(false);
        Destroy(expl, 0.25f);
        yield return(new WaitForSeconds(0.07f));

        fader.SetActive(true);
        faderAnim.SetTrigger("Fade");
        AudioFW.StopLoop("Ambience");
        GameObject[] enemies = GameObject.FindGameObjectsWithTag("Enemy");
        foreach (GameObject enemy in enemies)
        {
            Destroy(enemy);
        }
    }
예제 #3
0
 public void NameEntry()
 {
     Intro.SetActive(false);
     nameEntry.SetActive(true);
     nameEntryButton.Select();
     LeanTween.move(nameInteractables, Vector3.zero, .5f).setEaseOutBack().setOnComplete(menuMusic);
     AudioFW.StopLoop("IntroLoop");
     //AudioFW.AdjustLoopVolume("IntroLoop", 0f, .5f);
     PlayMenuMusic();
     AudioFW.Play("Whip");
 }
예제 #4
0
 private void Update()
 {
     if (currentTime > 1)
     {
         currentTime -= Time.deltaTime;
     }
     else
     {
         AudioFW.StopLoop("Clash_1st_Loop");
         AudioFW.PlayLoop("Clash_Intense_Loop");
     }
 }
예제 #5
0
 void StartBeam()
 {
     isDamaging = false;
     beamPoints.Clear();
     objectsHit    = new List <GameObject>();
     beamDistances = new List <float>();
     ShootBeam(beamStart.position, beamStart.up, currentMaxDistance, 0);
     if (isDamaging)
     {
         AudioFW.AdjustPitch("Laser", 2.5f);
         if (objectsHit[objectsHit.Count - 1].GetComponent <Destructible>() != null)
         {
             if (objectsHit[objectsHit.Count - 1].GetComponent <Destructible>().isFriendly)
             {
                 AudioFW.PlayLoop("Screamer");
             }
         }
     }
     else
     {
         AudioFW.AdjustPitch("Laser", 0.5f);
         AudioFW.StopLoop("Screamer");
     }
 }
예제 #6
0
 void StopShootSounds()
 {
     AudioFW.StopLoop("BurstLoop");
     AudioFW.PlayRandomPitch("BurstTail");
 }