/// <summary>
        /// Getting defined by user available potions
        /// </summary>
        /// <param name="place"> Where potions are </param>
        /// <param name="potions"> Amount </param>
        private void SetAvailablePotions(Enums.Place place, int potions)
        {
            switch (place)
            {
            case Enums.Place.backpack:
                _potionsInBackpack = potions;
                break;

            case Enums.Place.potionStack:
                _potionsOutside = potions;
                break;
            }
        }
        private void UpdateData(Enums.Place place, int value)
        {
            string _value = value.ToString();

            switch (place)
            {
            case Enums.Place.backpack:
                potionsInBackpack = _value;
                break;

            case Enums.Place.potionStack:
                potionsOutside = _value;
                break;
            }
        }
        /// <summary>
        /// Update potions count in app window while bot is running
        /// </summary>
        /// <param name="place"> Place of potions </param>
        /// <param name="potions"> Amount of potions </param>
        private void UpdatePotions(Enums.Place place, int potions)
        {
            string _potions = potions.ToString();

            switch (place)
            {
            case Enums.Place.backpack:
                potionsInBackpack = _potions;
                break;

            case Enums.Place.potionStack:
                potionsOutside = _potions;
                break;
            }
        }
        /// <summary>
        /// Setting user defined coordinates on screen to be able drag&drop stacks
        /// </summary>
        /// <param name="point"> Point on screen </param>
        /// <param name="selectedPlace"> Kind of selected place </param>
        private void SetCoordinates(POINT point, Enums.Place selectedPlace)
        {
            switch (selectedPlace)
            {
            case Enums.Place.backpack:
                _placeInBackpack = point;
                break;

            case Enums.Place.potionStack:
                _placeWithPotions = point;
                break;

            case Enums.Place.vialStack:
                _placeToDrop = point;
                break;
            }
        }
Пример #5
0
        private void SendMouseCoordinate(POINT point)
        {
            SendCoordinate(point, _coordinatesOfPlace);

            switch (_coordinatesOfPlace)
            {
            case Enums.Place.backpack:
                _coordinatesOfPlace    = Enums.Place.potionStack;
                coordinateSelectorText = "Set cursor above your potions stack and press spacebar";
                break;

            case Enums.Place.potionStack:
                _coordinatesOfPlace    = Enums.Place.vialStack;
                coordinateSelectorText = "Set cursor above your place to throw empty vials and press spacebar";
                break;

            case Enums.Place.vialStack:
                this.TryClose();
                break;
            }
        }
Пример #6
0
 public CoordinateSelectionViewModel()
 {
     _coordinatesOfPlace = Enums.Place.backpack;
     CoordinateSelectionView.CatchCoordinate += SendMouseCoordinate;
     coordinateSelectorText = "Set cursor above first place in your backpack and press spacebar";
 }