} // and its graphics instance #endregion #region CONSTRUCTORS public HackOverlay(EUCProcess proc, HackInput input) { BackColor = Color.Transparent; Input = input; Process = proc; Renderer = new Renderer(); FormThread = new Thread(() => { Form = new DrawForm(); Form.Shown += (o, e) => Renderer.Init(Form); Form.Resize += (o, e) => { Renderer.Dispose(); Renderer.Init(Form); SceneWorld = Renderer.MakeScene(); // size = 10mb SceneOverlay = Renderer.MakeScene(1024 * 1024 * 2); // size = 2mb GeomVisuals = Renderer.MakeGeometryBuffer(); // size = 2mb GeomMenu = Renderer.MakeGeometryBuffer(1024 * 1024); // size = 1mb Visuals = new Graphics(GeomVisuals); Menu = new Graphics(GeomMenu); }; Application.Run(Form); }); FormThread.IsBackground = true; Size = Vector2.Zero; //BaseContainer = new Frame(); //BaseContainer.BackColor = Color.Transparent; Controls = new List <Controls.Control>(); }
static void Main(string[] args) { //new Test().Run(); //return; Animation = new ConsoleAnimation(); Animation.Text = Name = string.Format("[ZMH5] Helios v.{0}", Assembly.GetExecutingAssembly().GetName().Version); Animation.Delimiter = " // "; Animation.RunningOutOfNews += (o, e) => Animation.AppendNews(Memes.Captions[new Random().Next(0, Memes.Captions.Length)]); Animation.Start(); Animation.Interval = (int)(1000f / 15f); Logger = new Logger(); Logger.PrintDate = Logger.PrintTime = false; Logger.Log("### [Helios] started ###"); Logger.Info("Loaded {0} memes", Memes.Captions.Length); LoadSettings(); CurrentSettings.Save(); LoadOffsets(); Offsets.Save("offsets.json"); //Wait for game Logger.Warning("WAITING FOR CSGO..."); while (!EUCProcess.IsProcessRunning("csgo")) { Thread.Sleep(500); } Hack = new Heke(); var thread = new Thread(() => { var cfg = new ConfigForm(); ConfigWindowHandle = cfg.Handle; Application.Run(cfg); }); thread.TrySetApartmentState(ApartmentState.STA); thread.Start(); Logger.Info("> Running hack!"); Hack.Run(); Console.ReadLine(); }