Exemplo n.º 1
0
        private void DrawMenu(int x, int y)
        {
            var font = d2d.CreateFont("Consolas", 11);

            d2d.FillRectangle(x - 5, y - 22, 260, 1500, d2d.CreateBrush(2, 2, 2, 255));

            foreach (mnIndex MnIdx in Enum.GetValues(typeof(mnIndex)))
            {
                var color = d2d.CreateBrush(255, 0, 0, 255);
                if (currMnIndex == MnIdx)
                {
                    color = d2d.CreateBrush(255, 191, 0, 255);
                }
                d2d.DrawText(GetMenuString(MnIdx), x, y = y + 20, font, color);
            }
        }
Exemplo n.º 2
0
        private void drawThread()
        {
            Direct2DRenderer pDevice = overlay.Graphics;

            while (doLoop)
            {
                if (!isGameActive())
                {
                    pDevice.BeginScene();
                    pDevice.ClearScene();
                    pDevice.EndScene();

                    while (!isGameActive() && doLoop)
                    {
                        Thread.Sleep(100);
                    }
                    if (!doLoop)
                    {
                        break;
                    }
                }


                watch.Reset();
                watch.Start();
                if ((GetAsyncKeyState((int)0x01) & 0x8000) != 0)
                {
                    if (!mouseDown)
                    {
                        justToggled = true;
                        mouseDown   = true;
                    }
                    else
                    {
                        justToggled = false;
                    }
                }
                else
                {
                    mouseDown   = false;
                    justToggled = false;
                }
                GetCursorPos(out mousePos);

                handleInput();

                pDevice.BeginScene();
                pDevice.ClearScene();

                if (Master.renderesp)
                {
                    RenderESP();
                }

                pDevice.FillRectangle(5 + Xshift, 5 + Yshift, 170, 210, blackBrush);
                pDevice.DrawRectangle(5 + Xshift, 5 + Yshift, 170, 210, 5, tealBrush);
                pDevice.DrawText("LysDick Hex", titleFont, tealBrush, 15 + Xshift, 10 + Yshift);

                pDevice.DrawRectangle(15 + Xshift, 50 + Yshift, 15, 15, 1, tealBrush);
                pDevice.DrawText("Enable Triggerbot", font, tealBrush, 35 + Xshift, 49 + Yshift);
                pDevice.DrawRectangle(15 + Xshift, 70 + Yshift, 15, 15, 1, tealBrush);
                pDevice.DrawText("Slow Mode", font, tealBrush, 35 + Xshift, 69 + Yshift);
                pDevice.DrawRectangle(15 + Xshift, 90 + Yshift, 15, 15, 1, tealBrush);
                pDevice.DrawText("ESP (15m)", font, tealBrush, 35 + Xshift, 89 + Yshift);
                pDevice.DrawRectangle(15 + Xshift, 110 + Yshift, 15, 15, 1, tealBrush);
                pDevice.DrawText("Bunny Hop (Space)", font, tealBrush, 35 + Xshift, 109 + Yshift);

                if (Master.enabled)
                {
                    pDevice.FillRectangle(16 + Xshift, 51 + Yshift, 12, 12, tealBrush);
                }
                if (Master.mode == 1)
                {
                    pDevice.FillRectangle(16 + Xshift, 71 + Yshift, 12, 12, tealBrush);
                }
                if (Master.renderesp)
                {
                    pDevice.FillRectangle(16 + Xshift, 91 + Yshift, 12, 12, tealBrush);
                }
                if (Master.doBHop)
                {
                    pDevice.FillRectangle(16 + Xshift, 111 + Yshift, 12, 12, tealBrush);
                }

                Yshift += 25;

                pDevice.DrawCircle(22 + Xshift, 117 + Yshift, 8, 1, tealBrush);
                pDevice.DrawText("0ms Delay", font, tealBrush, 35 + Xshift, 109 + Yshift);
                pDevice.DrawCircle(22 + Xshift, 137 + Yshift, 8, 1, tealBrush);
                pDevice.DrawText("20ms Delay", font, tealBrush, 35 + Xshift, 129 + Yshift);
                pDevice.DrawCircle(22 + Xshift, 157 + Yshift, 8, 1, tealBrush);
                pDevice.DrawText("80ms Delay", font, tealBrush, 35 + Xshift, 149 + Yshift);
                if (Master.delay == 0)
                {
                    pDevice.FillCircle(22 + Xshift, 117 + Yshift, 7, tealBrush);
                }
                if (Master.delay == 20)
                {
                    pDevice.FillCircle(22 + Xshift, 137 + Yshift, 7, tealBrush);
                }

                if (Master.delay == 80)
                {
                    pDevice.FillCircle(22 + Xshift, 157 + Yshift, 7, tealBrush);
                }
                while (watch.ElapsedMilliseconds < (50 / 3))
                {
                    Thread.Sleep(1);
                }
                Yshift -= 25;
                pDevice.EndScene();
            }
        }