public void Awake()
        {
            Instance     = this;
            useGUILayout = false;

            warpSound      = ScriptableObject.CreateInstance <FMODAsset>();
            warpSound.path = "event:/tools/gravcannon/fire";

            TechnologyMatrix = new List <TechMatrix.TechTypeData> [TechMatrix.techMatrix.Length];
            TechMatrix.InitTechMatrixList(ref TechnologyMatrix);

            if (Main.isExistsSMLHelperV2)
            {
                TechMatrix.IsExistsModdersTechTypes(ref TechnologyMatrix, TechMatrix.Known_Modded_TechTypes);
            }
            else
            {
                Logger.Log("[CheatManager] Warning:\n'SMLHelper.V2' not found! Some functions are not available!", LogType.Warning);
            }
            TechMatrix.SortTechLists(ref TechnologyMatrix);

            Buttons         = new List <GUIHelper.ButtonInfo>();
            toggleButtons   = new List <GUIHelper.ButtonInfo>();
            daynightTab     = new List <GUIHelper.ButtonInfo>();
            categoriesTab   = new List <GUIHelper.ButtonInfo>();
            vehicleSettings = new List <GUIHelper.ButtonInfo>();

            GUIHelper.CreateButtonsList(ButtonText.Buttons, GUIHelper.BUTTONTYPE.NORMAL_CENTER, ref Buttons);
            GUIHelper.CreateButtonsList(ButtonText.ToggleButtons, GUIHelper.BUTTONTYPE.TOGGLE_CENTER, ref toggleButtons);
            GUIHelper.CreateButtonsList(ButtonText.DayNightTab, GUIHelper.BUTTONTYPE.TAB_CENTER, ref daynightTab);
            GUIHelper.CreateButtonsList(ButtonText.CategoriesTab, GUIHelper.BUTTONTYPE.TAB_CENTER, ref categoriesTab);

            var    searchSeaGlide = new TechMatrix.TechTypeSearch(TechType.Seaglide);
            string seaglideName   = TechnologyMatrix[1][TechnologyMatrix[1].FindIndex(searchSeaGlide.EqualsWith)].Name;

            var searchSeamoth = new TechMatrix.TechTypeSearch(TechType.Seamoth);

            seamothName = TechnologyMatrix[0][TechnologyMatrix[0].FindIndex(searchSeamoth.EqualsWith)].Name;

            var searchExosuit = new TechMatrix.TechTypeSearch(TechType.Exosuit);

            exosuitName = TechnologyMatrix[0][TechnologyMatrix[0].FindIndex(searchExosuit.EqualsWith)].Name;

            var searchCyclops = new TechMatrix.TechTypeSearch(TechType.Cyclops);

            cyclopsName = TechnologyMatrix[0][TechnologyMatrix[0].FindIndex(searchCyclops.EqualsWith)].Name;

            string[] vehicleSetButtons = { $"{seamothName} Can Fly", $"{seaglideName} Speed Fast" };

            GUIHelper.CreateButtonsList(vehicleSetButtons, GUIHelper.BUTTONTYPE.TOGGLE_CENTER, ref vehicleSettings);

            daynightTab[4].Pressed    = true;
            categoriesTab[0].Pressed  = true;
            toggleButtons[17].Pressed = false;
            Buttons[7].Enabled        = false;
            Buttons[7].Pressed        = true;

            exosuitSpeedMultiplier = 1;
            cyclopsSpeedMultiplier = 1;
        }
Example #2
0
        private void InitItems()
        {
            foreach (KeyValuePair <string, string> key in Config.HotKeys)
            {
                hotkeyLabels.Add(key.Key);
                hotkeyButtons.Add(key.Value);
            }

            GUIHelper.CreateButtonsList(hotkeyButtons.ToArray(), GUIHelper.BUTTONTYPE.NORMAL_CENTER, ref buttonInfos);
        }