public void perder() { stopwatch.Stop(); estadoActual = EstadodeJuego.gameOver; pantallaPrincipal.Children.Clear(); pantallaPrincipal.Children.Add(new GameOver(menu)); }
public void menu() { estadoActual = EstadodeJuego.menu; pantallaPrincipal.Children.Clear(); pantallaPrincipal.Children.Add(new Menu(iniciar)); lblHertz.Visibility = Visibility.Hidden; stopwatch.Restart(); }
void Awake() { rutaArchivo = Application.persistentDataPath + "/datos.dat"; if (estadodeJuego == null) { estadodeJuego = this; DontDestroyOnLoad(gameObject); } else if (estadodeJuego != this) { Destroy(gameObject); } }
public void iniciar() { stopwatch = new Stopwatch(); stopwatch.Start(); if (aux == 0) { ThreadStart threadStart = new ThreadStart(actualizar); Thread threadPuntos = new Thread(threadStart); threadPuntos.Start(); aux = 1; } estadoActual = EstadodeJuego.gameplay; pantallaPrincipal.Children.Clear(); pantallaPrincipal.Children.Add(new Gameplay(perder)); lblHertz.Visibility = Visibility.Visible; }
public void perder() { estadoActual = EstadodeJuego.gameOver; }
public void iniciar() { estadoActual = EstadodeJuego.gameplay; pantallaPrincipal.Children.Clear(); pantallaPrincipal.Children.Add(new Gameplay(perder)); }