Exemplo n.º 1
0
        public void IntergrationMenu()
        {
            if (AdeptusIntergrationUtility.enabled_AlienRaces && Dev)
            {
                Listing_StandardExpanding listing_AlienRacesIntergration    = listing_Main.BeginSection(110);
                Listing_StandardExpanding listing_ImperialRacesIntergration = listing_AlienRacesIntergration.BeginSection(100);

                listing_AlienRacesIntergration.EndSection(listing_ImperialRacesIntergration);
                Listing_StandardExpanding listing_AeldariRacesIntergration = listing_AlienRacesIntergration.BeginSection(100);

                listing_AlienRacesIntergration.EndSection(listing_AeldariRacesIntergration);
                listing_Main.EndSection(listing_AlienRacesIntergration);
            }
            Listing_StandardExpanding listing_ArmouryIntergration = listing_Main.BeginSection(Listing_ArmouryIntergrationLength, false, 3);

            //   listing_ArmouryIntergration = listing_Main.BeginSection(MenuLengthIntergration, false, 0);
            listing_ArmouryIntergration.Label("Changes to these settings require a restart to take effect." + (Dev ? " patchesCount: " + PatchesCount : ""));
            Listing_StandardExpanding listing_General = listing_ArmouryIntergration.BeginSection(Listing_ArmouryIntergrationContents, true);

            listing_General.ColumnWidth *= 0.488f;
            bool flag = false;

            for (int i = 0; i < Patches.Count; i++)
            {
                var patch = Patches[i];
                if (!patch.optional)
                {
                    continue;
                }
                var status = settings.PatchDisabled[patch];
                if (!flag && i + 1 > Patches.Count / 2)
                {
                    listing_General.NewColumn();
                    flag = true;
                }
                listing_General.CheckboxLabeled(patch.label, ref status, patch.tooltip);

                settings.PatchDisabled[patch] = status;
            }
            listing_ArmouryIntergration.EndSection(listing_General);
            listing_Main.EndSection(listing_ArmouryIntergration);
        }