Ejemplo n.º 1
0
        static void selectNextReference()
        {
            bool[] array =
            {
                MarkerManager.IsMarkerVisible(MarkerType.CoM),
                MarkerManager.IsMarkerVisible(MarkerType.DCoM),
                MarkerManager.IsMarkerVisible(MarkerType.ACoM)
            };
            if (!array.Any(o => o))
            {
                return;
            }
            int  i     = (int)RCSBuildAid.ReferenceType;
            bool found = false;

            for (int j = 0; j < 3; j++)
            {
                i = LoopIndexSelect(0, 2, i);
                if (array [i])
                {
                    found = true;
                    break;
                }
            }
            if (found)
            {
                RCSBuildAid.SetReferenceMarker((MarkerType)i);
            }
        }
Ejemplo n.º 2
0
 protected override void content()
 {
     /* markers toggles */
     GUILayout.BeginVertical();
     {
         GUILayout.BeginHorizontal();
         {
             for (int i = 0; i < 3; i++)
             {
                 MarkerType marker        = (MarkerType)i;
                 bool       visibleBefore = MarkerManager.MarkerVisible(marker);
                 bool       visibleAfter  = GUILayout.Toggle(visibleBefore, marker.ToString());
                 if (visibleBefore != visibleAfter)
                 {
                     MarkerManager.SetMarkerVisibility(marker, visibleAfter);
                 }
             }
         }
         GUILayout.EndHorizontal();
         GUILayout.BeginHorizontal();
         {
             GUILayout.Label("Size", MainWindow.style.sizeLabel);
             Settings.marker_scale = GUILayout.HorizontalSlider(Settings.marker_scale, 0, 1);
         }
         GUILayout.EndHorizontal();
     }
     GUILayout.EndVertical();
 }
Ejemplo n.º 3
0
 public static void ReferenceButton()
 {
     if (GUILayout.Button(RCSBuildAid.ReferenceType.ToString(), MainWindow.style.smallButton))
     {
         selectNextReference();
     }
     else if (!MarkerManager.IsMarkerVisible(RCSBuildAid.ReferenceType))
     {
         selectNextReference();
     }
 }
Ejemplo n.º 4
0
 public static GameObject GetMarker(MarkerType comref)
 {
     return(MarkerManager.GetMarker(comref));
 }