int GetPlayerNum(PlayerController.Player player) { int playerNum = -1; switch (player) { case PlayerController.Player.Debug: case PlayerController.Player.One: playerNum = 0; break; case PlayerController.Player.Two: playerNum = 1; break; case PlayerController.Player.Three: playerNum = 2; break; case PlayerController.Player.Four: playerNum = 3; break; } return(playerNum); }
private void OnTriggerEnter2D(Collider2D collider) { if (isPressed) { return; } PlayerController.Player player = collider.GetComponent <PlayerController.Player>(); if (player != null) { if (player.CheckState(PlayerController.StateLabels.IsStomping)) { StartCoroutine(Press()); } } }
public void GameOver(PlayerController.Player playerVencedor) { Time.timeScale = 0; JogadorVencedorText.text = "O " + playerVencedor.ToString() + " É O VENCEDOR!"; GameOverPanel.SetActive(true); }