IEnumerator GameOverEnumerator(Vector2 cameraPos, float[] damageTaken, bool isQuit) { if (!isQuit) { Time.timeScale = 0.25f; for (float i = 0; i < (float)3 / 4; i += Time.deltaTime) { if (oneMoreChance) { break; } yield return(null); } } if (oneMoreChance) { oneMoreChance = false; } else { Time.timeScale = 1; cameraCont.GameOver(); starReward = (int)killSum / 5 + (int)currentGameTime / 6; gameOver = true; challengeCont.GameOver(isQuit); StartCoroutine(spawnCont.GameOver(isQuit)); healthAbilityOn = false; int recordValue = (data.highScoreTime < currentGameTime ? 1 : 0) + (data.highScoreKill < killSum ? 2 : 0); dataCont.SetData((int)currentGameTime, killSum, currentEnemiesKilled, damageTaken, recordValue); SaveCurrentGameData(damageTaken, isQuit); yield return(new WaitForSeconds(0.5f)); //TO avoid lag SaveAndLoad.SaveData(data); } }
//void FixedUpdate() //{ //} void GameOver() { isGameOver = true; myChallenge.GameOver(); SoundMScript.PlaySound("death"); animator.SetBool("isDeath", true); }
void GameOver() { myAudioSource.PlayOneShot(dead); isGameOver = true; anim.SetBool("death", true); myChallengeController.GameOver(); ls.gover = true; }
void GameOver() { isGameOver = true; myAudioPlayer.PlayOneShot(deadSFX); myChallengeController.GameOver(); }
void GameOver() { isGameOver = true; myChallengeController.GameOver(); }
void GameOver() { isGameOver = true; myAudioPlayer.PlayOneShot(deathSound); mychallengeController.GameOver(); }
void GameOver() { isGameOver = true; myChallengeController.GameOver(); GameControl.Restart(); }
void GameOver() { isGameOver = true; myChallengeController.GameOver(); OSCHandler.Instance.SendMessageToClient("pd", "/unity/musicStart", 0); }
void GameOver() { isGameOver = true; myChallengeController.GameOver(); Debug.Log("Game Over"); }