Ped's coords search

underWHAT

Active member
Joined
Mar 26, 2015
Messages
30
Reaction score
0
Hi guys. I neet to get all streaming peds coordinates and health, for that i try that code on C#:
Code:
for (int i = 0; i < 140; i++) //Loop, 140 - max. count of elements on pool
{
    uint aPed = ReadUInteger(handle, (uint)i * 0x7C4+ 0xB7CD98 ); // Offset of peds, 0x7C4 - size of one element 
    if (aPed != 0) // Is element valid?
    {
        int matrix = ReadInteger(handle, aPed+0x14 );// Get ped's coord matrix
        float x = ReadFloat(handle,matrix+0x30); // Try to get X coord, but error is there
        Console.WriteLine(i + ":\t" + aPed + "\t" + x); // 
    }
}
But i get OverflowException, when running that code. Maybe somebody have code to found peds coords?
 
Top