예제 #1
0
		public virtual void DrawOutline (bool isSelected, Menu _menu)
		{
			Color boxColor = Color.yellow;
			if (isSelected)
			{
				boxColor = Color.red;
			}
			for (int i=0; i<GetNumSlots (); i++)
			{
				if (i > 0)
				{
					boxColor = Color.blue;
				}
				DrawStraightLine.DrawBox (_menu.GetRectAbsolute (GetSlotRectRelative (i)), boxColor, 1f, false, 1);
			}

		}
예제 #2
0
		public override void DrawOutline (bool isSelected, Menu _menu)
		{
			if (dragType == DragElementType.EntireMenu)
			{
				DrawStraightLine.DrawBox (_menu.GetRectAbsolute (GetDragRectRelative ()), Color.white, 1f, false, 1);
			}
			else
			{
				if (elementName != "")
				{
					MenuElement element = MenuManager.GetElementWithName (_menu.title, elementName);
					if (element != null)
					{
						Rect dragBox = _menu.GetRectAbsolute (GetDragRectRelative ());
						dragBox.x += element.GetSlotRectRelative (0).x;
						dragBox.y += element.GetSlotRectRelative (0).y;
						DrawStraightLine.DrawBox (dragBox, Color.white, 1f, false, 1);
					}
				}
			}
			
			base.DrawOutline (isSelected, _menu);
		}