Example #1
0
        internal static void RegisterSettings()
        {
            var avatarSearchModeName = "AvatarSearchMode";

            var category = MelonPreferences.CreateCategory(SettingsCategory, "FavCat");

            DatabasePath        = category.CreateEntry("DatabasePath", "./UserData", "Database directory path", is_hidden: true, dont_save_default: false);
            ImageCachePath      = category.CreateEntry("ImageCachePath", "./UserData", "Image cache directory path", is_hidden: true, dont_save_default: false);
            AnnoyingMessageSeen = category.CreateEntry("AnnoyingMessageSeen", "", is_hidden: true);

            EnableAvatarFavs = category.CreateEntry("EnableAvatarFavs", true, "Enable avatar favorites (restart required)");
            EnableWorldFavs  = category.CreateEntry("EnableWorldFavs", true, "Enable world favorites (restart required)");
            EnablePlayerFavs = category.CreateEntry("EnablePlayerFavs", true, "Enable player favorites (restart required)");

            ImageCacheMode    = category.CreateEntry("ImageCachingMode", "full", "Image caching mode");
            ImageCacheMaxSize = category.CreateEntry("ImageCacheMaxSize", 4096, "Image cache max size (MB)");
            HidePopupAfterFav = category.CreateEntry("HidePopupAfterFav", true, "Hide favorite popup after (un)favoriting a world or a player");

            MakeClickSounds     = category.CreateEntry("MakeClickSounds", true, "Click sounds");
            AvatarSearchMode    = category.CreateEntry(avatarSearchModeName, "select", "Avatar search result action");
            SortPlayersByOnline = category.CreateEntry(nameof(SortPlayersByOnline), true, "Show offline players at the end of the list");

            SortPlayersByJoinable = category.CreateEntry(nameof(SortPlayersByJoinable), true, "Show players in private instances at the end of the list");

            ExpansionKitApi.RegisterSettingAsStringEnum(SettingsCategory, "ImageCachingMode", new [] { ("full", "Full local image cache (fastest, safest)"), ("fast", "Fast, use more RAM"), ("builtin", "Preserve RAM, more API requests") });
Example #2
0
        public void UiManagerInit()
        {
            BTKUtil.Log("BTK Standalone: Nameplate Mod - Starting up");

            instance = this;

            if (MelonHandler.Mods.Any(x => x.Info.Name.Equals("BTKCompanionLoader", StringComparison.OrdinalIgnoreCase)))
            {
                MelonLogger.Msg("Hold on a sec! Looks like you've got BTKCompanion installed, this mod is built in and not needed!");
                MelonLogger.Error("BTKSANameplateMod has not started up! (BTKCompanion Running)");
                return;
            }

            BTKUtil.Log(settingsCategory);

            MelonPreferences.CreateCategory(settingsCategory, "Nameplate Mod");
            MelonPreferences.CreateEntry <bool>(settingsCategory, hiddenCustomSetting, false, "Enable Custom Nameplates (Not ready)");
            MelonPreferences.CreateEntry <bool>(settingsCategory, hideFriendsNameplates, false, "Hide Friends Nameplates");
            MelonPreferences.CreateEntry <string>(settingsCategory, trustColourMode, "friends", "Trust Colour Mode");
            MelonPreferences.CreateEntry <bool>(settingsCategory, nameplateOutlineMode, false, "Nameplate Outline Background");
            MelonPreferences.CreateEntry <bool>(settingsCategory, nameplateAlwaysShowQuickStats, false, "Always Show Quick Stats");
            MelonPreferences.CreateEntry <bool>(settingsCategory, nameplateCloseRangeFade, false, "Close Range Fade");
            MelonPreferences.CreateEntry <bool>(settingsCategory, NameplateCloseRangeFadeFriends, false, "Close Range Fade Friends Only");
            MelonPreferences.CreateEntry <float>(settingsCategory, nameplateCloseRangeDistMin, 2f, "Close Range Min Distance");
            MelonPreferences.CreateEntry <float>(settingsCategory, nameplateCloseRangeDistMax, 3f, "Close Range Max Distance");
            MelonPreferences.CreateEntry <bool>(settingsCategory, nameplateRandomColours, false, "Random Nameplate Colours");
            ExpansionKitApi.RegisterSettingAsStringEnum(settingsCategory, trustColourMode, new[] { ("off", "Disable Trust Colours"), ("friends", "Show Friends Colour"), ("trustonly", "Ignore Friends Colour"), ("trustname", "Trust Colour On Name") });
Example #3
0
        public static void Init()
        {
            ExpansionKitApi.GetExpandedMenu(ExpandedMenu.SettingsMenu).AddSimpleButton("Optimize mirrors", OptimizeMirrors);
            ExpansionKitApi.GetExpandedMenu(ExpandedMenu.SettingsMenu).AddSimpleButton("Beautify mirrors", BeautifyMirrors);

            ExpansionKitApi.RegisterSettingAsStringEnum(MirrorResolutionUnlimiterMod.ModCategory,
                                                        MirrorResolutionUnlimiterMod.PixelLightsSetting,
                                                        new[] { ("default", "World default"), ("allow", "Force allow"), ("disable", "Force disable") });
Example #4
0
        public override void OnApplicationStart()
        {
            Logger = new MelonLogger.Instance("CameraResChanger");

            cat                = MelonPreferences.CreateCategory("CamResChange", "Camera Res Changer");
            LargerSizes        = MelonPreferences.CreateEntry("CamResChange", nameof(LargerSizes), true, "Enable Sizes > 8k (Needs 'Lag Free Screenshots') - This may break/work with new VRC versions, test when the game updates");
            AdjustSizeAtLaunch = MelonPreferences.CreateEntry("CamResChange", nameof(AdjustSizeAtLaunch), false, "Adjust Camera res at game launch");
            DefaultSize        = MelonPreferences.CreateEntry("CamResChange", nameof(DefaultSize), "4k", "Camera res for Adjust at Launch");
            ExpansionKitApi.RegisterSettingAsStringEnum("CamResChange",
                                                        nameof(DefaultSize),
                                                        new[]
Example #5
0
        public static void SetupPrefs()
        {
            MelonPreferences.CreateCategory(SettingCategory, "Safety Presets Mod");

            MelonPreferences.CreateEntry <string>(SettingCategory, PublicPreset, "No Preset Selected", "Public Preset");
            MelonPreferences.CreateEntry <string>(SettingCategory, FriendsPreset, "No Preset Selected", "Friends Preset");
            MelonPreferences.CreateEntry <string>(SettingCategory, PrivatePreset, "No Preset Selected", "Private Preset");

            ExpansionKitApi.RegisterSettingAsStringEnum(SettingCategory, PublicPreset, Settings.selectablePresets);
            ExpansionKitApi.RegisterSettingAsStringEnum(SettingCategory, FriendsPreset, Settings.selectablePresets);
            ExpansionKitApi.RegisterSettingAsStringEnum(SettingCategory, PrivatePreset, Settings.selectablePresets);


            MelonPreferences.CreateEntry <bool>(SettingCategory, ChangeInPublic, false, "Change safety setting preset in public?");
            MelonPreferences.CreateEntry <bool>(SettingCategory, ChangeInFriends, false, "Change safety setting preset in friends?");
            MelonPreferences.CreateEntry <bool>(SettingCategory, ChangeInPrivate, false, "Change safety setting preset in privates?");
        }
Example #6
0
        internal static void RegisterSettings()
        {
            MelonPrefs.RegisterCategory(FavCatCategory, "FavCat");

            MelonPrefs.RegisterString(FavCatCategory, DatabasePathSettings, "./UserData", "Database directory path", true);
            MelonPrefs.RegisterString(FavCatCategory, ImageCacheSettings, "./UserData", "Image cache directory path", true);

            MelonPrefs.RegisterBool(FavCatCategory, EnableAvatarFavs, true, "Enable avatar favorites (restart required)");
            MelonPrefs.RegisterBool(FavCatCategory, EnableWorldFavs, true, "Enable world favorites (restart required)");
            MelonPrefs.RegisterBool(FavCatCategory, EnablePlayerFavs, true, "Enable player favorites (restart required)");

            MelonPrefs.RegisterString(FavCatCategory, ImageCachingMode, "full", "Image caching mode");
            MelonPrefs.RegisterInt(FavCatCategory, ImageCacheMaxSize, 4096, "Image cache max size (MB)");
            MelonPrefs.RegisterBool(FavCatCategory, HidePopupAfterFav, true, "Hide favorite popup after (un)favoriting a world or a player");

            // shared mode can't be multi-threaded, so hide this until other parts of code are ready for ST patterns
            MelonPrefs.RegisterBool(FavCatCategory, UseSharedMode, false, "Support multiple VRC instances (slower, restart required)", true);

            ExpansionKitApi.RegisterSettingAsStringEnum(FavCatCategory, ImageCachingMode, new [] { ("full", "Full local image cache (fastest, safest)"), ("fast", "Fast, use more RAM"), ("builtin", "Preserve RAM, more API requests") });
Example #7
0
 private static void AddEnumSettings()
 {
     ExpansionKitApi.RegisterSettingAsStringEnum(SettingsCategory, SettingScreenshotFormat, new [] { ("png", "PNG"), ("jpeg", "JPEG") });
Example #8
0
 public static void UIXinit()
 {
     ExpansionKitApi.RegisterSettingAsStringEnum("FLuxMod",
                                                 nameof(Main.amapi_ModsFolder),
                                                 new[]