Exemplo n.º 1
0
 public void SpawnPlayer()
 {
     if (GetPlayer == null)
     {
         _playerPawn = Instantiate(_playerPawnObject, _playerSpawn.GetSpawnLocation(), _playerSpawn.GetSpawnRotation());
         _playerPawn.GetComponent <PlayerMovement>().DenyInput();
     }
     else
     {
         _playerPawn.transform.position = _playerSpawn.GetSpawnLocation();
         _playerPawn.transform.rotation = _playerSpawn.GetSpawnRotation();
     }
 }