Exemplo n.º 1
0
    private void Start()
    {
        _collider = GetComponent <Collider>();
        _playerMovementController = GetComponent <PlayerMovementController>();

        transform.position = PlayerSpawningController.GetSpawningPoint(GetComponent <PlayerMovementController>().PlayerId);
    }
Exemplo n.º 2
0
    private void Respawn()
    {
        transform.position = PlayerSpawningController.GetSpawningPoint();

        GetComponent <Rigidbody>().velocity = Vector3.zero;

        Instantiate(_respawn, transform.position, Quaternion.identity);
    }