Inheritance: MonoBehaviour
Beispiel #1
0
        private void InitializeNewServices()
        {
            this.newDraggingService = new MyDragging(this.diagram);
            Binding binding = new Binding("IsOn");

            binding.Source = this.newDraggingService;
            binding.Mode   = BindingMode.TwoWay;
            this.toggleDrag.SetBinding(RadToggleButton.IsCheckedProperty, binding);
            binding        = new Binding("IsRestrictedToBounds");
            binding.Source = this.newDraggingService;
            binding.Mode   = BindingMode.TwoWay;
            this.IsRestrictedToBounds.SetBinding(RadToggleButton.IsCheckedProperty, binding);
            binding        = new Binding("UseRotaitonBounds");
            binding.Source = this.newDraggingService;
            binding.Mode   = BindingMode.TwoWay;
            this.useRotaitonBounds.SetBinding(RadToggleButton.IsCheckedProperty, binding);

            this.newRotationService = new MyRotation(this.diagram)
            {
                RotationStep = 45
            };
            binding        = new Binding("RotationStep");
            binding.Source = this.newRotationService;
            binding.Mode   = BindingMode.TwoWay;
            this.rotationStep.SetBinding(TextBox.TextProperty, binding);

            this.newResizingService = new MyResizing(this.diagram);
            binding        = new Binding("CanResizeWidth");
            binding.Source = this.newResizingService;
            binding.Mode   = BindingMode.TwoWay;
            this.resizeWidth.SetBinding(RadToggleButton.IsCheckedProperty, binding);
            binding        = new Binding("CanResizeHeight");
            binding.Source = this.newResizingService;
            binding.Mode   = BindingMode.TwoWay;
            this.resizeHeight.SetBinding(RadToggleButton.IsCheckedProperty, binding);
        }
Beispiel #2
0
        private async Task <bool> GetCombat()
        {
            switch ((int)Core.Me.ClassLevel)
            {
            case 50:
                return(await MyRotation.CombatLvL50());

            case 49:
            case 48:
                return(await MyRotation.CombatLvL48());

            case 47:
            case 46:
                return(await MyRotation.CombatLvL46());

            case 45:
            case 44:
                return(await MyRotation.CombatLvL44());

            case 43:
            case 42:
                return(await MyRotation.CombatLvL42());

            case 41:
            case 40:
                return(await MyRotation.CombatLvL40());

            case 39:
            case 38:
                return(await MyRotation.CombatLvL38());

            case 37:
            case 36:
                return(await MyRotation.CombatLvL36());

            case 35:
            case 34:
                return(await MyRotation.CombatLvL34());

            case 33:
            case 32:
                return(await MyRotation.CombatLvL32());

            case 31:
            case 30:
                return(await MyRotation.CombatLvL30());

            case 29:
            case 28:
                return(await MyRotation.CombatLvL28());

            case 27:
            case 26:
                return(await MyRotation.CombatLvL26());

            case 25:
            case 24:
                return(await MyRotation.CombatLvL24());

            case 23:
            case 22:
                return(await MyRotation.CombatLvL22());

            case 21:
            case 20:
                return(await MyRotation.CombatLvL20());

            case 19:
            case 18:
                return(await MyRotation.CombatLvL18());

            case 17:
            case 16:
                return(await MyRotation.CombatLvL16());

            case 15:
                return(await MyRotation.CombatLvL15());

            case 14:
                return(await MyRotation.CombatLvL14());

            case 13:
            case 12:
                return(await MyRotation.CombatLvL12());

            case 11:
            case 10:
                return(await MyRotation.CombatLvL10());

            case 9:
            case 8:
                return(await MyRotation.CombatLvL8());

            case 7:
            case 6:
                return(await MyRotation.CombatLvL6());

            case 5:
            case 4:
                return(await MyRotation.CombatLvL4());

            case 3:
            case 2:
                return(await MyRotation.CombatLvL2());

            default:
                return(await MyRotation.CombatLvL1());
            }
        }
Beispiel #3
0
 private async Task <bool> GetRest()
 {
     return(await MyRotation.Rest());
 }