internal static void Initialize() { Menu = MainMenu.AddMenu("Core", "Core"); #region Ticks var tickSlider = Menu.Add("TicksPerSecond", new Slider("Ticks Per Second", 25, 1, 75)); tickSlider.OnValueChange += delegate(ValueBase <int> sender, ValueBase <int> .ValueChangeArgs args) { Game.TicksPerSecond = args.NewValue; }; Game.TicksPerSecond = tickSlider.CurrentValue; Menu.AddLabel(" Recommended value: 25."); Menu.AddLabel("Note: Ticks per second means how often the Game.OnTick event should be fired."); Menu.AddLabel("This means this option is not a humanizer, just a performance option."); Menu.AddLabel("Example: 25 t/s means Game.OnTick is being fired 25 times per second."); Menu.AddLabel("Higher values mean more load each second, which could reduce FPS slightly."); #endregion Ticks Gapcloser.AddMenu(); #region Hacks var hacksMenu = Menu.AddSubMenu("Hacks"); var ingameChat = hacksMenu.Add("IngameChat", new CheckBox("Enable InGame Chat", Hacks.IngameChat)); ingameChat.OnValueChange += delegate(ValueBase <bool> sender, ValueBase <bool> .ValueChangeArgs args) { Hacks.IngameChat = args.NewValue; }; Hacks.IngameChat = ingameChat.CurrentValue; var antiAfk = hacksMenu.Add("AntiAFK", new CheckBox("Enable Anti AFK", Hacks.AntiAFK)); antiAfk.OnValueChange += delegate(ValueBase <bool> sender, ValueBase <bool> .ValueChangeArgs args) { Hacks.AntiAFK = args.NewValue; }; Hacks.AntiAFK = antiAfk.CurrentValue; var movementHack = hacksMenu.Add("MovementHack", new CheckBox("Enable Movement Hack", Hacks.MovementHack)); movementHack.OnValueChange += delegate(ValueBase <bool> sender, ValueBase <bool> .ValueChangeArgs args) { Hacks.MovementHack = args.NewValue; }; Hacks.MovementHack = movementHack.CurrentValue; var towersRange = hacksMenu.Add("TowerRanges", new CheckBox("Draw Tower Ranges", Hacks.TowerRanges)); towersRange.OnValueChange += delegate(ValueBase <bool> sender, ValueBase <bool> .ValueChangeArgs args) { Hacks.TowerRanges = args.NewValue; }; Hacks.TowerRanges = towersRange.CurrentValue; var renderWatermark = hacksMenu.Add("RenderWatermark", new CheckBox("Draw EloBuddy Watermark", Hacks.RenderWatermark)); renderWatermark.OnValueChange += delegate(ValueBase <bool> sender, ValueBase <bool> .ValueChangeArgs args) { Hacks.RenderWatermark = args.NewValue; }; Hacks.RenderWatermark = renderWatermark.CurrentValue; Hacks.ZoomHack = false; #endregion Hacks if (Sandbox.SandboxConfig.IsBuddy) { StreamingMode.LoadMenu(); } }
public static void Init(string[] args) { if (_initialized) { return; } _initialized = true; // Set thread culture CultureInfo.DefaultThreadCurrentCulture = CultureInfo.InvariantCulture; CultureInfo.DefaultThreadCurrentUICulture = CultureInfo.InvariantCulture; Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture; Thread.CurrentThread.CurrentUICulture = CultureInfo.InvariantCulture; // Check if we are on streaming mode if (SandboxConfig.StreamingMode) { IsStreamingMode = true; StreamingMode.Initialize(); } // Run Bootstrap Init BootstrapRun.Initialize(); }