Beispiel #1
0
        public override void Load()
        {
            DebugMode                    = Config.Bind("Custom", "Enable Debug Mode", false);
            StreamerMode                 = Config.Bind("Custom", "Enable Streamer Mode", false);
            GhostsSeeTasks               = Config.Bind("Custom", "Ghosts See Remaining Tasks", true);
            GhostsSeeRoles               = Config.Bind("Custom", "Ghosts See Roles", true);
            HostSeesVotesLog             = Config.Bind("Custom", "Host Sees Votes Log", false);
            StreamerModeReplacementText  = Config.Bind("Custom", "Streamer Mode Replacement Text", "\n\nThe Other Roles");
            StreamerModeReplacementColor = Config.Bind("Custom", "Streamer Mode Replacement Text Hex Color", "#87AAF5FF");


            Ip             = Config.Bind("Custom", "Custom Server IP", "127.0.0.1");
            Port           = Config.Bind("Custom", "Custom Server Port", (ushort)22023);
            defaultRegions = ServerManager.DefaultRegions;

            UpdateRegions();

            GameOptionsData.RecommendedImpostors = GameOptionsData.MaxImpostors = Enumerable.Repeat(3, 16).ToArray(); // Max Imp = Recommended Imp = 3
            GameOptionsData.MinPlayers           = Enumerable.Repeat(4, 15).ToArray();                                // Min Players = 4

            DebugMode = Config.Bind("Custom", "Enable Debug Mode", false);
            Instance  = this;
            CustomOptionHolder.Load();
            CustomColors.Load();

            Harmony.PatchAll();
        }
Beispiel #2
0
        public override void Load()
        {
            DebugMode    = Config.Bind("Custom", "Enable Debug Mode", false);
            StreamerMode = Config.Bind("Custom", "Enable Streamer Mode", false);
            StreamerModeReplacementText  = Config.Bind("Custom", "Streamer Mode Replacement Text", "\n\nThe Other Roles");
            StreamerModeReplacementColor = Config.Bind("Custom", "Streamer Mode Replacement Text Hex Color", "#87AAF5FF");


            Ip   = Config.Bind("Custom", "Custom Server IP", "127.0.0.1");
            Port = Config.Bind("Custom", "Custom Server Port", (ushort)22023);

            CustomRegion = new DnsRegionInfo(Ip.Value, "Custom", StringNames.NoTranslation, Ip.Value, Port.Value);
            ServerManager serverManager = DestroyableSingleton <ServerManager> .Instance;

            IRegionInfo[] regions = ServerManager.DefaultRegions;

            regions = regions.Concat(new IRegionInfo[] { CustomRegion.Cast <IRegionInfo>() }).ToArray();
            ServerManager.DefaultRegions   = regions;
            serverManager.AvailableRegions = regions;
            serverManager.SaveServers();

            GameOptionsData.RecommendedImpostors = GameOptionsData.MaxImpostors = Enumerable.Repeat(3, 16).ToArray(); // Max Imp = Recommended Imp = 3
            GameOptionsData.MinPlayers           = Enumerable.Repeat(4, 15).ToArray();                                // Min Players = 4

            DebugMode = Config.Bind("Custom", "Enable Debug Mode", false);
            Instance  = this;
            CustomOptionHolder.Load();
            CustomColors.Load();

            Harmony.PatchAll();
        }
Beispiel #3
0
        public override void Load()
        {
            ModTranslation.Load();
            Logger                       = Log;
            DebugMode                    = Config.Bind("Custom", "Enable Debug Mode", false);
            StreamerMode                 = Config.Bind("Custom", "Enable Streamer Mode", false);
            GhostsSeeTasks               = Config.Bind("Custom", "Ghosts See Remaining Tasks", true);
            GhostsSeeRoles               = Config.Bind("Custom", "Ghosts See Roles", true);
            GhostsSeeVotes               = Config.Bind("Custom", "Ghosts See Votes", true);
            ShowRoleSummary              = Config.Bind("Custom", "Show Role Summary", true);
            HideNameplates               = Config.Bind("Custom", "Hide Nameplates", false);
            ShowLighterDarker            = Config.Bind("Custom", "Show Lighter / Darker", false);
            HideTaskArrows               = Config.Bind("Custom", "Hide Task Arrows", false);
            ShowPopUpVersion             = Config.Bind("Custom", "Show PopUp", "0");
            StreamerModeReplacementText  = Config.Bind("Custom", "Streamer Mode Replacement Text", "\n\nThe Other Roles GM");
            StreamerModeReplacementColor = Config.Bind("Custom", "Streamer Mode Replacement Text Hex Color", "#87AAF5FF");
            DebugRepo                    = Config.Bind("Custom", "Debug Hat Repo", "");

            Ip             = Config.Bind("Custom", "Custom Server IP", "127.0.0.1");
            Port           = Config.Bind("Custom", "Custom Server Port", (ushort)22023);
            defaultRegions = ServerManager.DefaultRegions;

            UpdateRegions();

            GameOptionsData.RecommendedImpostors = Enumerable.Repeat(3, 16).ToArray();
            GameOptionsData.MaxImpostors         = Enumerable.Repeat(15, 16).ToArray(); // Max Imp = Recommended Imp = 3
            GameOptionsData.MinPlayers           = Enumerable.Repeat(4, 15).ToArray();  // Min Players = 4

            DebugMode = Config.Bind("Custom", "Enable Debug Mode", false);
            Instance  = this;
            CustomOptionHolder.Load();
            RoleInfo.Load();
            CustomColors.Load();
            RandomGenerator.Initialize();

            Harmony.PatchAll();
            Patches.SubmergedPatch.Patch();
            SubmergedCompatibility.Initialize();
        }