Пример #1
0
        public void UpdateMe()
        {
            radialBranch.UpdateLines(ActionRadial, ItemRadial.OuterRadius);
            ItemRadial.UpdateArrows();

            if (IsAnyPointerDown() == false)
            {
                return;
            }

            // Deactivate the menu if there was a mouse click outside of the menu.
            var mousePos = CommonInput.mousePosition;

            if (ItemRadial.IsPositionWithinRadial(mousePos) == false && ActionRadial.IsPositionWithinRadial(mousePos) == false)
            {
                this.SetActive(false);
            }
        }
        public void Update()
        {
            radialBranch.UpdateDirection();
            ItemRadial.transform.localPosition = radialBranch.MenuPosition;
            ItemRadial.UpdateArrows();
            radialBranch.UpdateLineSize(ActionRadial, ItemRadial.transform.position);
            UpdateItemRadialRotation();

            if (IsAnyPointerDown() == false)
            {
                return;
            }

            // Deactivate the menu if there was a mouse click outside of the menu.
            var mousePos = CommonInput.mousePosition;

            if (ItemRadial.IsPositionWithinRadial(mousePos) == false && ActionRadial.IsPositionWithinRadial(mousePos) == false)
            {
                this.SetActive(false);
            }
        }