Esempio n. 1
0
        private void FlatSDK_DrawGraphics(object sender, DrawGraphicsEventArgs e)
        {
            var gfx = e.Graphics;

            if (ESPXOptions.bLoadColorsBTN == 1)
            {
                loadColorsFromFile(gfx);
                ESPXOptions.bLoadColorsBTN = 0;
            }
            if (ESPXOptions.bSaveBTN == 1)
            {
                SerializeStatic.Serialize(typeof(ESPXOptions), "ESPXCFG.xml");
                ESPXOptions.bSaveBTN = 0;
            }
            if (ESPXOptions.bLoadBTN == 1)
            {
                SerializeStatic.Deserialize(typeof(ESPXOptions), "ESPXCFG.xml");
                ESPXOptions.bLoadBTN = 0;
            }


            LocalPlayer = FlatSDK.GetLocalPlayer();

            if (LocalPlayer == null)
            {
                return;
            }
            if (LocalPlayer.extra == null)
            {
                return;
            }



            if (entityDrawPositions.Count > 0)
            {
                entityDrawPositions.Clear();
            }

            foreach (var entity in listEntityItems)
            {
                //var dump = ObjectDumper.Dump(entity.eItem);
                //var dump = ObjectDumper.Dump(entity);

                //if (entity.type != 82) { continue; }

                // Console.Write("\n!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!n");
                //Console.Write(dump);
                //
                //myarray.Add(entity.eItem.id.ToString()  +  ":" + entity.eItem.gname.ToString() );
                try
                {
                    DrawItemWeapon(gfx, entity, entity.eItem.id.ToString());
                }
                catch {
                    Console.Write("DrawItemWeapon error\n");
                }
            }
        }
Esempio n. 2
0
        public override async Task Load()
        {
            FlatSDK.DrawGraphics  += FlatSDK_DrawGraphics;
            FlatSDK.SetupGraphics += FlatSDK_SetupGraphics;

            var ESPFolderObject = FlatSDK.menuBase.AddFolderElement(ref ESPOptions.bESPFolder, "ESP Options", FlatSDKInternal.folderonoff);

            FlatSDK.menuBase.AddTextElement(ref ESPOptions.bSnapLines, "SnapLines ESP ", FlatSDKInternal.onoff, ESPFolderObject);
            FlatSDK.menuBase.AddTextElement(ref ESPOptions.bShowHealth, "Health ESP", FlatSDKInternal.onoff, ESPFolderObject);
            FlatSDK.menuBase.AddTextElement(ref ESPOptions.bShowBox, "Box ESP", FlatSDKInternal.onoff, ESPFolderObject);
            FlatSDK.menuBase.AddTextElement(ref ESPOptions.bShowDistance, "Distance ESP", FlatSDKInternal.onoff, ESPFolderObject);
            FlatSDK.menuBase.AddTextElement(ref ESPOptions.bShowState, "State ESP", FlatSDKInternal.onoff, ESPFolderObject);

            FlatSDK.menuBase.AddTextElement(ref ESPOptions.bSaveBTN, "Save", FlatSDKInternal.savebtn, ESPFolderObject);
            FlatSDK.menuBase.AddTextElement(ref ESPOptions.bLoadBTN, "Load", FlatSDKInternal.loadbtn, ESPFolderObject);


            SerializeStatic.Deserialize(typeof(ESPOptions), "ESPCFG.xml");
        }
Esempio n. 3
0
        public override async Task Load()
        {
            FlatSDK.DrawGraphics  += FlatSDK_DrawGraphics;
            FlatSDK.SetupGraphics += FlatSDK_SetupGraphics;

            var FolderObject = FlatSDK.menuBase.AddFolderElement(ref AimOptions.bAimFolder, "Aimbot Options", FlatSDKInternal.folderonoff);

            FlatSDK.menuBase.AddTextElement(ref AimOptions.bEnabled, "Aimbot", FlatSDKInternal.onoff, FolderObject);
            FlatSDK.menuBase.AddTextElement(ref AimOptions.bDrawFow, "Draw Fov", FlatSDKInternal.onoff, FolderObject);
            FlatSDK.menuBase.AddTextElement(ref AimOptions.bSmooth, "Smooth", FlatSDKInternal.offx2x3x4x5x6, FolderObject);
            FlatSDK.menuBase.AddTextElement(ref AimOptions.bFovInt, "Fov", FlatSDKInternal.aimFov, FolderObject);
            FlatSDK.menuBase.AddTextElement(ref AimOptions.bPredict, "Predict", FlatSDKInternal.offx2x3x4x5x6, FolderObject);
            FlatSDK.menuBase.AddTextElement(ref AimOptions.bYAxis, "Y Axis", FlatSDKInternal.offx2x3x4x5x6, FolderObject);
            FlatSDK.menuBase.AddTextElement(ref AimOptions.bAimKeyINT, "Aim Key", aimkeys, FolderObject);
            FlatSDK.menuBase.AddTextElement(ref AimOptions.bSaveBTN, "Save", FlatSDKInternal.savebtn, FolderObject);
            FlatSDK.menuBase.AddTextElement(ref AimOptions.bLoadBTN, "Load", FlatSDKInternal.loadbtn, FolderObject);


            SerializeStatic.Deserialize(typeof(AimOptions), "AimCFG.xml");
        }
Esempio n. 4
0
        private static void FlatSDK_DrawGraphics(object sender, DrawGraphicsEventArgs e)
        {
            var gfx = e.Graphics;

            if (ESPOptions.bSaveBTN == 1)
            {
                SerializeStatic.Serialize(typeof(ESPOptions), "ESPCFG.xml");
                ESPOptions.bSaveBTN = 0;
            }
            if (ESPOptions.bLoadBTN == 1)
            {
                SerializeStatic.Deserialize(typeof(ESPOptions), "ESPCFG.xml");
                ESPOptions.bLoadBTN = 0;
            }


            LocalPlayer = FlatSDK.GetLocalPlayer();

            if (LocalPlayer == null)
            {
                return;
            }
            if (LocalPlayer.extra == null)
            {
                return;
            }

            foreach (var ent in FlatSDK.GetEntities())
            {
                if (ent.type != 82)
                {
                    continue;
                }

                DrawBlip(gfx, ent);
            }
        }
Esempio n. 5
0
        public override async Task Load()
        {
            FlatSDK.DrawGraphics  += FlatSDK_DrawGraphics;
            FlatSDK.SetupGraphics += FlatSDK_SetupGraphics;

            FlatSDKInternal.SetSDKModifier(FlatSDKInternal.KAccessModifier.Items);

            var ESPXFolderObject = FlatSDK.menuBase.AddFolderElement(ref ESPXOptions.bESPXFolder, "ESPX Options", FlatSDKInternal.folderonoff);

            FlatSDK.menuBase.AddTextElement(ref ESPXOptions.bLockInScreen, "Jail Items In Screen", FlatSDKInternal.onoff, ESPXFolderObject);
            FlatSDK.menuBase.AddTextElement(ref ESPXOptions.bShowAllItems, "Force Show All Items", FlatSDKInternal.onoff, ESPXFolderObject);
            FlatSDK.menuBase.AddTextElement(ref ESPXOptions.bFixOverview, "Fix Overview", FlatSDKInternal.onoff, ESPXFolderObject);
            FlatSDK.menuBase.AddTextElement(ref ESPXOptions.bTextWithBg, "Background Color Active", FlatSDKInternal.onoff, ESPXFolderObject);

            //FlatSDK.menuBase.AddTextElement(ref ESPXOptions.bShowBox, "Box ESP", FlatSDKInternal.onoff, ESPXFolderObject);
            //FlatSDK.menuBase.AddTextElement(ref ESPXOptions.bShowDistance, "Distance ESP", FlatSDKInternal.onoff, ESPXFolderObject);

            FlatSDK.menuBase.AddTextElement(ref ESPXOptions.bLoadColorsBTN, "Reload Config File", FlatSDKInternal.savebtn, ESPXFolderObject);
            FlatSDK.menuBase.AddTextElement(ref ESPXOptions.bSaveBTN, "Save", FlatSDKInternal.savebtn, ESPXFolderObject);
            FlatSDK.menuBase.AddTextElement(ref ESPXOptions.bLoadBTN, "Load", FlatSDKInternal.loadbtn, ESPXFolderObject);


            SerializeStatic.Deserialize(typeof(ESPXOptions), "ESPXCFG.xml");
        }
Esempio n. 6
0
        private static void FlatSDK_DrawGraphics(object sender, DrawGraphicsEventArgs e)
        {
            var gfx = e.Graphics;

            if (AimOptions.bSaveBTN == 1)
            {
                SerializeStatic.Serialize(typeof(AimOptions), "AimCFG.xml");
                AimOptions.bSaveBTN = 0;
            }
            if (AimOptions.bLoadBTN == 1)
            {
                SerializeStatic.Deserialize(typeof(AimOptions), "AimCFG.xml");
                AimOptions.bLoadBTN = 0;
            }

            LocalPlayer = FlatSDK.GetLocalPlayer();

            if (LocalPlayer == null)
            {
                return;
            }
            if (LocalPlayer.extra == null)
            {
                return;
            }

            var entList = GetEntitiesAsArray();

            var AimTargets = new AimTarget[entList.Length];

            float fClosestDist = -1;

            float ScreenCenterX = FlatSDK.Overlay.Width / 2.0f;
            float ScreenCenterY = FlatSDK.Overlay.Height / 2.0f;


            if (AimOptions.bDrawFow == 1)
            {
                gfx.DrawCircle(FlatSDKInternal.IRenderer._opakwhite, ScreenCenterX, ScreenCenterY, AimOptions.bFovArray[AimOptions.bFovInt], 2);
            }



            for (int i = 0; i < entList.Length; i++)
            {
                var current = entList[i];
                if (current.type != 82)
                {
                    continue;
                }


                var clampPos = current.HeadBone.position - current.position;


                bool w2sHead = FlatSDK.WorldToScreen(FlatSDK.Overlay.Width, FlatSDK.Overlay.Height, new Vector3(current.HeadBone.position.X, current.HeadBone.position.Y - (AimOptions.bPredict * 2), current.HeadBone.position.Z - (AimOptions.bYAxis * 8)), out Vector2 HeadPosition);
                AimTargets[i]                   = new AimTarget();
                AimTargets[i].Screen2D          = HeadPosition;
                AimTargets[i].uniqueID          = current.uniqueID;
                AimTargets[i].CrosshairDistance = Vector2.Distance(HeadPosition, new Vector2(ScreenCenterX, ScreenCenterY));



                // isInFov
                if (BestTargetUniqID == -1)
                {
                    if (isInside(ScreenCenterX, ScreenCenterY, AimOptions.bFovArray[AimOptions.bFovInt], AimTargets[i].Screen2D.X, AimTargets[i].Screen2D.Y))
                    {
                        fClosestDist     = AimTargets[i].CrosshairDistance;
                        BestTargetUniqID = AimTargets[i].uniqueID;
                    }
                }

                //if (BestTargetUniqID == -1)
                //{
                //    if (w2sHead)
                //    {
                //        gfx.FillCircle(FlatSDKInternal.IRenderer._opakwhite, HeadPosition.X, HeadPosition.Y, 5);
                //    }
                //}
                //else
                //{
                //    if (w2sHead)
                //    {
                //        gfx.FillCircle(FlatSDKInternal.IRenderer._red, HeadPosition.X, HeadPosition.Y, 5);
                //    }
                //}
            }


            if (FlatSDK.IsKeyPushedDown(AimOptions.bAimKeys[AimOptions.bAimKeyINT]))
            {
                if (BestTargetUniqID != -1)
                {
                    var best = FindAimTargetByUniqueID(AimTargets, BestTargetUniqID);

                    if (best != null)
                    {
                        // kek

                        {
                            var roundPos = new Vector2((float)Math.Round(best.Screen2D.X), (float)Math.Round(best.Screen2D.Y));
                            AimAtPosV2(roundPos.X, roundPos.Y, false);
                        }
                    }
                }
            }
            else
            {
                BestTargetUniqID = -1;
            }
        }