예제 #1
0
        public static void Initialize()
        {
            dummyState    = new KeyboardState();
            previousState = dummyState;
            currentState  = Keyboard.GetState();

            KeyBinds.Load();
        }
예제 #2
0
        public static void Update()
        {
            previousState = currentState;
            currentState  = Pigeon.IsInFocus ? Keyboard.GetState() : dummyState;

            foreach (var key in KeyBinds.BoundKeys)
            {
                if (IsPressed(key) && !Pigeon.Console.IsDisplaying)
                {
                    string boundCommand = KeyBinds.GetKeyBind(key);
                    Pigeon.Console.ExecuteCommand(boundCommand);
                }
            }
        }