コード例 #1
0
        public static List <Point> GetInventory()
        {
            Console.WriteLine("Please press 'A' while hovering over the first inventory slot");
            while (Console.ReadKey().Key != ConsoleKey.A)
            {
                Thread.Yield();
            }
            var cursorPos = Cursor.Position;

            Console.WriteLine("\nFirst item slot position: " + cursorPos);
            var inventory = AutoSwitch.GenerateInventory(cursorPos);

            return(inventory);
        }
コード例 #2
0
        private static void InputManagerOnOnKeyboardEvent(VirtualKeyCode key, KeyState state)
        {
            if (state != KeyState.Up)
            {
                return;
            }

            // Handle prayer state
            bool swappedPrayers = false;
            bool swappedItems   = false;

            swappedPrayers = PrayerSwitch.ActivePrayer(key);
            swappedItems   = AutoSwitch.ActiveSwitches(key, swappedPrayers);
            SpecialAttack.DoSpecialAttack(key, swappedItems, swappedPrayers);

            var exitKey = LowLevelInput.Converters.KeyCodeConverter.ToVirtualKeyCode((int)Settings.Instance.ExitKey);

            if (exitKey == key)
            {
                _stop = true;
            }
        }
コード例 #3
0
 public static List <int> GetAutoSwitchItems(bool status = true)
 {
     return(AutoSwitch.AutoswitchItems(status));
 }