コード例 #1
0
    public void ReplaceRestartController(GameControllerType newValue)
    {
        var index     = GameComponentsLookup.RestartController;
        var component = (RestartControllerComponent)CreateComponent(index, typeof(RestartControllerComponent));

        component.Value = newValue;
        ReplaceComponent(index, component);
    }
コード例 #2
0
        private void SetCurrentDeviceId(string deviceId)
        {
            if (!_isEnable)
            {
                return;
            }

            var controllerType = GetGameControllerType(deviceId);

            if (CurrentControllerType == controllerType)
            {
                return;
            }

            CurrentControllerType = controllerType;
            RaisePropertyChanged(nameof(CurrentControllerType));
            GameControllerChanged?.Invoke(this, controllerType);
        }