예제 #1
0
    private void UpdateDeathState()
    {
        if (entity.HasControl)
        {
            GUI_Controller.Current.Show(false);
        }

        _playerMotor.OnDeath(state.IsDead);
        _playerRenderer.OnDeath(state.IsDead);
        _playerWeapons.OnDeath(state.IsDead);
    }
    private void UpdateDeathState()
    {
        if (entity.IsOwner)
        {
            if (state.IsDead)
            {
                GameController.Current.state.AlivePlayers--;
            }
            else
            {
                GameController.Current.state.AlivePlayers++;
            }
        }

        if (entity.HasControl)
        {
            GUI_Controller.Current.Show(!state.IsDead);
        }

        _playerMotor.OnDeath(state.IsDead);
        _playerRenderer.OnDeath(state.IsDead);
        _playerWeapons.OnDeath(state.IsDead);
    }
    private void UpdateDeathState()
    {
        if (entity.HasControl)
        {
            GUI_Controller.Current.Show(false);
        }

        _playerMotor.OnDeath(state.IsDead);
        _playerRenderer.OnDeath(state.IsDead);
        _playerWeapons.OnDeath(state.IsDead);

        if (entity.IsOwner && state.IsDead)
        {
            StartCoroutine(Respawn());
        }
    }