Beispiel #1
0
        private static void Main(string[] args)
        {
            Console.ForegroundColor = ConsoleColor.White;
            string[] guid = Guid.NewGuid().ToString().Split('-');
            Console.Title = (guid[0] + guid[1] + "|VentrixCode#6897|" + guid[2] + guid[3]).Replace("-", "");
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            for (int i = 0; i < 3; i++)
            {
                Console.WriteLine(Guid.NewGuid().ToString().Replace("-", ""));
            }
            Console.WriteLine("Waiting for G");
            do
            {
                //Program.PubgProcess = ((IEnumerable<Process>) Process.GetProcessesByName("TslGame")).FirstOrDefault<Process>();
                Program.PubgProcess = Process.GetProcesses().FirstOrDefault(x => x.ProcessName.GetHashCode() == -219875547);
                Thread.Sleep(100);
            }while (Program.PubgProcess == null);
            Console.WriteLine("G Proc {0}", (object)Program.PubgProcess.Id);
            Console.WriteLine("Init PayPass");
            Program.Client = new HSClient();
            if (Program.Client.connect())
            {
                Console.ForegroundColor = ConsoleColor.Green;
                Console.WriteLine("PayPass step 1/2 OK");
                Console.ForegroundColor = ConsoleColor.White;

                Console.WriteLine("Loading PayPass, wait few seconds...");
                Thread.Sleep(2000);
                if (Program.Client.Handshake(Program.PubgProcess.Id, 10))
                {
                    Console.ForegroundColor = ConsoleColor.Green;
                    Console.WriteLine("PayPass step 2/2 OK");
                    Console.WriteLine("PayPass Completed");
                    Console.ForegroundColor = ConsoleColor.White;
                    IntPtr zero = IntPtr.Zero;
                    Console.WriteLine("Looking for Fenster...");
                    IntPtr window;
                    do
                    {
                        window = Program.FindWindow("UnrealWindow", (string)null);
                        Thread.Sleep(100);
                    }while (window == IntPtr.Zero);
                    Console.ForegroundColor = ConsoleColor.Green;
                    Console.WriteLine("Fenster Found {0}", (object)window.ToInt32());
                    Console.ForegroundColor = ConsoleColor.White;
                    Thread.Sleep(1000);
                    Program.Pubg = new PUBG((ulong)Program.PubgProcess.Id, Program.Client);
                    if (!Program.Pubg.Start())
                    {
                        Console.WriteLine("Failed to load");
                        Environment.Exit(0);
                    }
                    Application.Run((Form) new PGVisual.Overlay.Overlay(window));
                }
                else
                {
                    Console.ForegroundColor = ConsoleColor.Red;
                }
                Console.WriteLine("PayPass step 2 fail");
            }
            else
            {
                Console.ForegroundColor = ConsoleColor.Red;
            }
            Console.WriteLine("PayPass step 1 fail");
        }
Beispiel #2
0
        private void UpdateThread()
        {
            while (PUBG.FindWindow("UnrealWindow", (string)null) != IntPtr.Zero)
            {
                //if (Convert.ToBoolean(GetAsyncKeyState(Module1.VK_F10) & 0x8000))
                //{
                //    this.DroppedItemGroupArray = 0L;
                //    this.pADroppedItemGroup = 0L;
                //    this.pUItem = 0L;
                //    this.Itemid = 0;


                //    Console.ForegroundColor = ConsoleColor.DarkBlue;
                //    Console.WriteLine("Cleared");
                //    Console.ForegroundColor = ConsoleColor.Black;
                //}

                //if (Convert.ToBoolean(GetAsyncKeyState(Module1.VK_F9) & 0x8000))
                //{
                //    this._items = new ConcurrentBag<Item>();

                //    Console.ForegroundColor = ConsoleColor.DarkBlue;
                //    Console.WriteLine("Cleared2");
                //    Console.ForegroundColor = ConsoleColor.Black;
                //}

                if (Convert.ToBoolean(GetAsyncKeyState(Module1.VK_F7) & 0x8000))
                {
                    if (farDistance)
                    {
                        farDistance             = false;
                        Console.ForegroundColor = ConsoleColor.Blue;
                        Console.WriteLine("Switched to short Distance Pointers");
                        Console.ForegroundColor = ConsoleColor.White;
                    }
                    else
                    {
                        Console.ForegroundColor = ConsoleColor.Blue;
                        Console.WriteLine("Switched to long Distance Pointers");
                        Console.ForegroundColor = ConsoleColor.White;
                        farDistance             = true;
                    }
                }


                //if (Convert.ToBoolean(GetAsyncKeyState(Module1.VK_F6) & 0x8000))
                //{
                //    ulong pointer = this._client.ReadPtr(this.BaseAddress + 0x3D88F10);
                //    ulong UWorld = this._client.ReadPtr(pointer + 0x0);


                //}



                try
                {
                    // ulong UWorld = this._client.ReadPtr(this._client.ReadPtr(this.BaseAddress + 0x3d87f10));
                    //ulong UWorld = this._client.ReadPtr(this._client.ReadPtr(this.BaseAddress + 0x262D30));

                    ulong UWorld = this._client.ReadPtr(this._client.ReadPtr(this.BaseAddress + 0x3D88F10));

                    if ((long)UWorld != 0L)
                    {
                        ulong GameInstance = this._client.ReadPtr(UWorld + 320UL);
                        if ((long)GameInstance != 0L)
                        {
                            ulong LocalPlayerArray = this._client.ReadPtr(GameInstance + 56UL);
                            if ((long)LocalPlayerArray != 0L)
                            {
                                ulong localPlayer = this._client.ReadPtr(LocalPlayerArray);
                                if ((long)localPlayer != 0L)
                                {
                                    ulong PlayerController = this._client.ReadPtr(localPlayer + 48UL);
                                    if ((long)PlayerController != 0L)
                                    {
                                        ulong PlayerCameraManager = this._client.ReadPtr(PlayerController + 1096UL);
                                        if ((long)PlayerCameraManager != 0L)
                                        {
                                            this._cameraCache = this._client.ReadMemory <FCameraCacheEntry>(PlayerCameraManager + 1056UL);
                                            ulong num5 = this._client.ReadPtr(localPlayer + 88UL);
                                            if ((long)num5 != 0L)
                                            {
                                                ulong num6 = this._client.ReadPtr(num5 + 128UL);
                                                if ((long)num6 != 0L)
                                                {
                                                    ulong num7 = this._client.ReadPtr(num6 + 48UL);
                                                    if ((long)num7 != 0L)
                                                    {
                                                        ulong actorPtr = this._client.ReadPtr(PlayerController + 1064UL);
                                                        if ((long)actorPtr != 0L)
                                                        {
                                                            this._localActor = new LocalActor(actorPtr, localPlayer);
                                                            ulong entityList = this._client.ReadPtr(num7 + 0xA0);          //entity list
                                                            int   num8       = this._client.ReadMemory <int>(num7 + 0xA8); //entity

                                                            if (Program.Pubg.farDistance == true)
                                                            {
                                                                entityList = this._client.ReadPtr(num7 + 0xB0);          //entity list
                                                                num8       = this._client.ReadMemory <int>(num7 + 0xB8); //entity
                                                            }

                                                            if (Program.Pubg.farDistance == false)
                                                            {
                                                                entityList = this._client.ReadPtr(num7 + 0xA0);          //entity list
                                                                num8       = this._client.ReadMemory <int>(num7 + 0xA8); //entity
                                                            }


                                                            if ((long)entityList != 0L)
                                                            {
                                                                if (num8 > 0)
                                                                {
                                                                    ConcurrentBag <Actor> concurrentBag  = new ConcurrentBag <Actor>();
                                                                    ConcurrentBag <Item>  concurrentBagI = new ConcurrentBag <Item>();
                                                                    //ConcurrentBag<Car> concurrentBagCar = new ConcurrentBag<Car>();

                                                                    for (int index = 0; index < num8; ++index)
                                                                    {
                                                                        ulong entity = this.getActor(index, entityList);
                                                                        if ((long)entity != 0L)
                                                                        {
                                                                            int id = this._client.ReadMemory <int>(entity + 24UL);
                                                                            if (id == this._playerClasses[0] || id == this._playerClasses[1])
                                                                            {
                                                                                Actor actor2 = new Actor(entity);
                                                                                if (actor2 != null && actor2.IsValid())
                                                                                {
                                                                                    concurrentBag.Add(actor2);
                                                                                }
                                                                            }


                                                                            if (id == this._itemClasses[1] && (true == false))
                                                                            {
                                                                                ulong DroppedItemGroupArray = this._client.ReadPtr(entity + 0x2E8);

                                                                                if ((long)DroppedItemGroupArray != 0L)
                                                                                {
                                                                                    int itemCount = this._client.ReadMemory <int>(entity + 0x2F0);



                                                                                    // TBitArray test = this._client.ReadMemory<TBitArray>(entity + 0x300);

                                                                                    for (int j = 0; j < itemCount; j++)
                                                                                    {
                                                                                        Console.WriteLine("funny");

                                                                                        ulong pADroppedItemGroup = this._client.ReadPtr(DroppedItemGroupArray + j * 0x10);
                                                                                        int   Itemid             = this._client.ReadMemory <int>(pADroppedItemGroup + 0x18);
                                                                                        if (Itemid == this._itemClasses[0])
                                                                                        {
                                                                                            ulong pUItem = this._client.ReadPtr(pADroppedItemGroup + 0x4e0);
                                                                                            //Console.WriteLine("item");
                                                                                            ulong pUItemFString = this._client.ReadPtr(pUItem + 0x40);
                                                                                            //Console.WriteLine("fstring");
                                                                                            ulong pItemName = this._client.ReadPtr(pUItemFString + 0x28);
                                                                                            //Console.WriteLine("itemname");
                                                                                            this.readItem = null;
                                                                                            this.readItem = this._client.read(pItemName);
                                                                                            var result = System.Text.Encoding.UTF8.GetString(readItem);
                                                                                            var str    = Regex.Replace(result, @"\s", "");
                                                                                            str = Regex.Replace(str, @"[^\x0d\x0a\x20-\x7e\t]", "");


                                                                                            if (str != string.Empty && (long)pUItem != 0L && (long)pUItemFString != 0L && (long)pItemName != 0L)
                                                                                            {
                                                                                                ulong rootComp = Program.Client.ReadPtr(entity + 392UL);
                                                                                                this._cameraCache = this._client.ReadMemory <FCameraCacheEntry>(PlayerCameraManager + 1056UL);
                                                                                                var position = this._client.ReadMemory <Vector3>(pADroppedItemGroup + 0x254);
                                                                                                var relative = this._client.ReadMemory <Vector3>(pADroppedItemGroup + 0x2D0);
                                                                                                Console.WriteLine(str + " " + position.X + " " + position.Y + " " + position.Z + " " + relative.X + " " + relative.Y + " " + relative.Z);

                                                                                                Vector3 screenloc;
                                                                                                bool    abc = worldToScreen(position + relative, out screenloc);

                                                                                                if (abc)
                                                                                                {
                                                                                                    Item item = new Item(id, str, screenloc, entity);
                                                                                                    item.position3D = position + relative;
                                                                                                    concurrentBagI.Add(item);
                                                                                                    Console.WriteLine("abc");
                                                                                                }
                                                                                            }
                                                                                        }
                                                                                    }
                                                                                }
                                                                                DroppedItemGroupArray = 0;
                                                                            }
                                                                        }
                                                                    }
                                                                    this._actors = concurrentBag;
                                                                    this._items  = concurrentBagI;
                                                                    //this._cars = concurrentBagCar;
                                                                }
                                                            }
                                                        }
                                                    }
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
                catch (Exception ex)
                {
                }
                Thread.Sleep(1000 / 60);
            }
        }
Beispiel #3
0
 // Token: 0x06000279 RID: 633 RVA: 0x00009674 File Offset: 0x00007874
 private void UpdateThread()
 {
     while (PUBG.FindWindow("UnrealWindow", null) != IntPtr.Zero)
     {
         try
         {
             ulong num;
             for (num = 0UL; num == 0UL; num = this._client.ReadPtr(this.BaseAddress + 64524048UL))
             {
             }
             num = this._client.ReadPtr(num);
             if (num != 0UL)
             {
                 ulong num2 = this._client.ReadPtr(num + 320UL);
                 if (num2 != 0UL)
                 {
                     ulong num3 = this._client.ReadPtr(num2 + 56UL);
                     if (num3 != 0UL)
                     {
                         ulong num4 = this._client.ReadPtr(num3);
                         if (num4 != 0UL)
                         {
                             ulong num5 = this._client.ReadPtr(num4 + 48UL);
                             if (num5 != 0UL)
                             {
                                 ulong num6 = this._client.ReadPtr(num5 + 1096UL);
                                 if (num6 != 0UL)
                                 {
                                     this._cameraCache = this._client.ReadMemory <FCameraCacheEntry>(num6 + 1056UL);
                                     ulong num7 = this._client.ReadPtr(num4 + 88UL);
                                     if (num7 != 0UL)
                                     {
                                         ulong num8 = this._client.ReadPtr(num7 + 128UL);
                                         if (num8 != 0UL)
                                         {
                                             ulong num9 = this._client.ReadPtr(num8 + 48UL);
                                             if (num9 != 0UL)
                                             {
                                                 ulong num10 = this._client.ReadPtr(num5 + 1064UL);
                                                 if (num10 != 0UL)
                                                 {
                                                     this._localActor = new LocalActor(num10, num4);
                                                     ulong num11 = this._client.ReadPtr(num9 + 160UL);
                                                     int   num12 = this._client.ReadMemory <int>(num9 + 168UL);
                                                     if (num11 != 0UL && num12 > 0)
                                                     {
                                                         ConcurrentBag <Actor> concurrentBag = new ConcurrentBag <Actor>();
                                                         for (int i = 0; i < num12; i++)
                                                         {
                                                             ulong actor = this.getActor(i, num11);
                                                             if (actor != 0UL)
                                                             {
                                                                 int num13 = this._client.ReadMemory <int>(actor + 24UL);
                                                                 if (num13 == this._playerClasses[0] || num13 == this._playerClasses[1])
                                                                 {
                                                                     Actor actor2 = new Actor(actor);
                                                                     if (actor2 != null && actor2.IsValid())
                                                                     {
                                                                         concurrentBag.Add(actor2);
                                                                     }
                                                                 }
                                                             }
                                                         }
                                                         this._actors = concurrentBag;
                                                     }
                                                 }
                                             }
                                         }
                                     }
                                 }
                             }
                         }
                     }
                 }
             }
         }
         catch (Exception)
         {
         }
         Thread.Sleep(5);
     }
 }