Ah sorry DJ Tsunami i forgotten to write that down.
I used the PrintToChatAll function. I read every value in a 4 byte step becouse the size of a single m_iAmmo cell is 4 byte.
I used the valve developer community site to find out more about the hl2 memory structures.
You simply paste this code on the top of the EquipClientCustom() function directly before the first if() statement.
Code:
for(new a = 0, tmpVal = 0; a < 100; a+=4) {
tmpVal = GetEntData(client, ammo_offset + a, 4);
PrintToChatAll("Offset %i contains %i", a, tmpVal);
}
Remember to get the ammo_offset of the m_iAmmo array with
Code:
new ammo_offset = FindSendPropOffs("CDODPlayer", "m_iAmmo");
The last 3 chat messages (dont remember how many lines exactly) had shown random values. I think this is becouse the m_iAmmo array in dods only contains 22 cells.
Anyway, i spawned with any class and wrote down the chat output. Then i compared the ammo i had ingame with the chatoutput values and connected the offsets.
__________________