/* Disabled for now * private new async void Update() * { * * for (; ; ) * { * * if (!this.isRunning || !this.isAimbot) * { * await Task.Delay(1000); * } * else * { * if (this.isAimKey) * { * int keyState = (int)Form1.GetKeyState((int)this.mainAimKey); * if (this.isHold) * { * if (keyState >= 0) * { * await Task.Delay(1); * continue; * } * } * else if (keyState != 0) * { * await Task.Delay(1); * continue; * } * } * * * Color pixel_Color; * * if (Customcolor.Checked == true) * { * int r = int.Parse(Redinput.Text); * int g = int.Parse(Greeninput.Text); * int b = int.Parse(Blueinput.Text); * pixel_Color = Color.FromArgb(r, g, b); * } * else * { * pixel_Color = Color.FromArgb(this.GetColor(this.color)); * } * * int pixelx; * int pixely; * * * if (this.isAimbot) * { * Point[] array = this.PixelSearch(new Rectangle((this.xSize - this.fovX) / 2, (this.ySize - this.fovY) / 2, this.fovX, this.fovY), pixel_Color, this.colorVariation); * if (array.Length != 0) * { * try * { * bool pressDown = false; * * Point[] array2 = (from t in array * orderby t.Y * select t).ToArray<Point>(); * List<Vector2> list = new List<Vector2>(); * for (int j = 0; j < array2.Length; j++) * { * Vector2 current = new Vector2((float)array2[j].X, (float)array2[j].Y); * if (!(from t in list * where (t - current).Length() < 60f || Math.Abs(t.X - current.X) < 60f * select t).Any()) * { * list.Add(current); * if (list.Count > 5) * { * break; * } * } * } * * //pixelx = Convert.ToInt32(SmoothX.Value); * //pixely = Convert.ToInt32(SmoothY.Value); * * Vector2 vector = (from t in list * select t - new Vector2((float)(this.xSize / 2), (float)(this.ySize / 2)) into t * orderby t.Length() * select t).ElementAt(0) + new Vector2(1f, (float)this.offsetY); * * if (this.PixelSearch(new Rectangle((this.xSize - pixelx) / 2, (this.ySize - pixely) / 2, pixelx, pixely), pixel_Color, this.colorVariation).Length != 0) * { * * int x = Convert.ToInt32(this.delayx); * await Task.Delay(x); * this.Move((int)(vector.X * (float)this.speed3), (int)(vector.Y * (float)this.speed3), pressDown); * continue; * } * else * { * this.Move((int)(vector.X * (float)this.speed), (int)(vector.Y * (float)this.speed), pressDown); * continue; * } * } * catch (Exception ex) * { * Console.WriteLine("Main Ex." + ((ex != null) ? ex.ToString() : null)); * continue; * } * return; * } * * } * } * * * * } * } */ private int GetColor(Form1.ColorType color) { if (color == Form1.ColorType.Red) { return(0x9A0000); } if (color != Form1.ColorType.Purple) { return(0xA224A2); } return(11480751); }
public Form1() { this.InitializeComponent(); this.Text = "iBaseult"; this.isTriggerbot = this.GetKey <bool>("isTriggerbot"); this.isAimbot = this.GetKey <bool>("isAimbot"); this.speed = this.GetKey <decimal>("speed"); this.speed3 = this.GetKey <decimal>("speed3"); this.delayx = this.GetKey <decimal>("delayx"); this.Bhop = this.GetKey <decimal>("Bhop"); this.fovX = this.GetKey <int>("fovX"); this.fovY = this.GetKey <int>("fovY"); this.color = (Form1.ColorType) this.GetKey <int>("color"); this.mainAimKey = (Form1.AimKey) this.GetKey <int>("mainAimKey"); this.Bhopxkey = (Form1.Bhopkey) this.GetKey <int>("Bhopxkey"); this.isAimKey = this.GetKey <bool>("isAimKey"); this.isHold = this.GetKey <bool>("isHold"); this.monitor = this.GetKey <int>("monitor"); this.isTriggerbot = this.GetKey <bool>("isTriggerbot"); this.offsetY = this.GetKey <int>("offsetY"); this.msShootTime = this.GetKey <int>("msShootTime"); this.isRecoil = this.GetKey <bool>("isRecoil"); this.isBhop = this.GetKey <bool>("isBhop"); Form1.ColorType colorType = this.color; if (colorType != Form1.ColorType.Red) { if (colorType == Form1.ColorType.Purple) { this.PurpleRadio.Checked = true; } } else { this.RedRadio.Checked = true; } this.UpdateUI(); this.IsHoldToggle.Checked = this.isHold; //this.AimbotBtt.Checked = this.isAimbot; //this.RecoilBtt.Checked = this.isRecoil; this.Bhopbox.Checked = this.isBhop; this.AimKeyToggle.Checked = this.isAimKey; this.AimKeyToggle.Checked = this.isBhop; //this.Speed.Value = this.speed; //this.Speed3.Value = this.speed3; //this.Delayx.Value = this.delayx; this.Bhopinput.Value = this.Bhop; //this.FovXNum.Value = this.fovX; //this.FovYNum.Value = this.fovY; this.TriggerbotBtt.Checked = this.isTriggerbot; //this.offsetNum.Value = this.offsetY; this.FireRateNum.Value = this.msShootTime; foreach (string text in Enum.GetNames(typeof(Form1.AimKey))) { this.contextMenuStrip1.Items.Add(text); } this.contextMenuStrip1.ItemClicked += delegate(object o, ToolStripItemClickedEventArgs e) { this.mainAimKey = (Form1.AimKey)Enum.Parse(typeof(Form1.AimKey), e.ClickedItem.ToString()); this.SetKey("mainAimKey", (int)this.mainAimKey); this.UpdateUI(); }; foreach (string text in Enum.GetNames(typeof(Form1.Bhopkey))) { this.contextMenuStrip2.Items.Add(text); } this.contextMenuStrip2.ItemClicked += delegate(object o, ToolStripItemClickedEventArgs e) { this.Bhopxkey = (Form1.Bhopkey)Enum.Parse(typeof(Form1.Bhopkey), e.ClickedItem.ToString()); this.SetKey("Bhopxkey", (int)this.Bhopxkey); this.UpdateUI(); }; this.AutoSize = false; base.AutoScaleMode = AutoScaleMode.Font; this.Font = new Font("Trebuchet MS", 10f, FontStyle.Regular, GraphicsUnit.Point, 204); }