private static void InitCommandsAndFreeConvars(On.RoR2.Console.orig_InitConVars orig, Console self) { void RemoveCheatFlag (BaseConVar cv) { cv.flags &= AllFlagsNoCheat; } orig(self); RemoveCheatFlag(self.FindConVar("sv_time_transmit_interval")); RemoveCheatFlag(self.FindConVar("run_scene_override")); RemoveCheatFlag(self.FindConVar("stage1_pod")); self.FindConVar("timescale").helpText += " Use time_scale instead!"; self.FindConVar("director_combat_disable").helpText += " Use no_enemies instead!"; self.FindConVar("timestep").helpText += " Let the DebugToolkit team know if you need this convar."; self.FindConVar("cmotor_safe_collision_step_threshold").helpText += " Let the DebugToolkit team know if you need this convar."; self.FindConVar("cheats").helpText += " But you already have the DebugToolkit mod installed..."; var mmConvar = (IntConVar) self.FindConVar("max_messages"); if (mmConvar.value == 25) { mmConvar.SetString("100"); } }
private static void InitCommandsAndFreeConvars(On.RoR2.Console.orig_InitConVars orig, RoR2.Console self) { void removeCheatFlag(RoR2.ConVar.BaseConVar cv) { cv.flags &= AllFlagsNoCheat; } orig(self); removeCheatFlag(self.FindConVar("sv_time_transmit_interval")); removeCheatFlag(self.FindConVar("run_scene_override")); removeCheatFlag(self.FindConVar("stage1_pod")); self.FindConVar("timescale").helpText += " Use time_scale instead!"; self.FindConVar("director_combat_disable").helpText += " Use no_enemies instead!"; self.FindConVar("timestep").helpText += " Let the ror2cheats team know if you need this convar."; self.FindConVar("cmotor_safe_collision_step_threshold").helpText += " Let the ror2cheats team know if you need this convar."; self.FindConVar("cheats").helpText += " But you already have the RoR2Cheats mod installed..."; }