public InputConfigInitSystem(Contexts contexts, ISessionState sessionState)
        {
            _inputContext = contexts.userInput;
            _sessionState = sessionState;

            _sessionState.CreateExitCondition(typeof(InputConfigInitSystem));
            SingletonManager.Get <SubProgressBlackBoard>().Add();
        }
示例#2
0
        private void InitKeyReceiver(UserInputContext context)
        {
            var recevier = new KeyReceiver(Layer.Env + 2, BlockType.None);

            recevier.AddAction(UserInputKey.LockCursor, (data) =>
            {
                //暂时屏蔽
                _contexts.ui.uI.IsShowCrossHair = true;
            });
            recevier.AddAction(UserInputKey.UnlockCursor, (data) =>
            {
                //暂时屏蔽
                _contexts.ui.uI.IsShowCrossHair = false;
            });
            context.userInputManager.Instance.RegisterKeyReceiver(recevier);
        }
示例#3
0
        private void InitKeyhandler(UserInputContext context)
        {
            var keyHandler = new KeyHandler(Layer.Env + 2, BlockType.None);

            keyHandler.BindKeyAction(UserInputKey.LockCursor, (data) =>
            {
                //暂时屏蔽
                _contexts.ui.uI.IsShowCrossHair = true;
            });
            keyHandler.BindKeyAction(UserInputKey.UnlockCursor, (data) =>
            {
                //暂时屏蔽
                _contexts.ui.uI.IsShowCrossHair = false;
            });
            context.userInputManager.Instance.RegisterKeyhandler(keyHandler);
        }
 public InputCollectSystem(Contexts contexts)
 {
     _userInputContext = contexts.userInput;
     _playerContext    = contexts.player;
 }