Current Ammo in the clip
0A96: 0@ = actor $PLAYER_ACTOR struct
0@ += 0x718 // Current Weapon Slot
0A8D: 1@ = read_memory 0@ size 1 virtual_protect 0
0A96: 0@ = actor $PLAYER_ACTOR struct
0@ += 0x5A0 // Start of weapon data (28 bytes)
1@ *= 28
005A: 0@ += 1@ // Get weapon structure
0@ += 8 // Pointer to "Ammo in clip"
0A8D: 3@ = read_memory 0@ size 1 virtual_protect 0 // Ammo in clip
3@ is the ammo in the clip.
-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.
Maximum Ammo in the clip :
{$CLEO}
const
FIRETYPE_MELEE = 0
FIRETYPE_INSTANT_HIT = 1
FIRETYPE_PROJECTILE = 2
FIRETYPE_AREA_EFFECT = 3
FIRETYPE_CAMERA = 4
FIRETYPE_USE = 5
end
0000: NOP
while true
wait 0
0470: 1@ = actor $PLAYER_ACTOR current_weapon
0A96: 0@ = actor $PLAYER_ACTOR struct
0AA8: call_function_method 0x5E6580 struct 0@ num_params 0 pop 0 cSkillIndex 2@ // CPed__getWeaponSkillIndex
0AA7: call_function 0x743C60 num_params 2 pop 2 cSkillIndex 2@ sWeaponType 1@ pclWeaponInfo 0@ // getWeaponInfo
//0@ += 0x00 // CWeaponInfo.m_eFireType
0A8D: 3@ = read_memory 0@ size 4 virtual_protect 0
if
3@ == FIRETYPE_INSTANT_HIT
then
0@ += 0x20 // CWeaponInfo.m_sMaxClipAmmo
0A8D: 4@ = read_memory 0@ size 2 virtual_protect 0
// 4@ will contain the maximum ammo in clip.
end
end
4@ is the maximum ammo count that the clip can contain.
0A96: 0@ = actor $PLAYER_ACTOR struct
0@ += 0x718 // Current Weapon Slot
0A8D: 1@ = read_memory 0@ size 1 virtual_protect 0
0A96: 0@ = actor $PLAYER_ACTOR struct
0@ += 0x5A0 // Start of weapon data (28 bytes)
1@ *= 28
005A: 0@ += 1@ // Get weapon structure
0@ += 8 // Pointer to "Ammo in clip"
0A8D: 3@ = read_memory 0@ size 1 virtual_protect 0 // Ammo in clip
3@ is the ammo in the clip.
-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.
Maximum Ammo in the clip :
{$CLEO}
const
FIRETYPE_MELEE = 0
FIRETYPE_INSTANT_HIT = 1
FIRETYPE_PROJECTILE = 2
FIRETYPE_AREA_EFFECT = 3
FIRETYPE_CAMERA = 4
FIRETYPE_USE = 5
end
0000: NOP
while true
wait 0
0470: 1@ = actor $PLAYER_ACTOR current_weapon
0A96: 0@ = actor $PLAYER_ACTOR struct
0AA8: call_function_method 0x5E6580 struct 0@ num_params 0 pop 0 cSkillIndex 2@ // CPed__getWeaponSkillIndex
0AA7: call_function 0x743C60 num_params 2 pop 2 cSkillIndex 2@ sWeaponType 1@ pclWeaponInfo 0@ // getWeaponInfo
//0@ += 0x00 // CWeaponInfo.m_eFireType
0A8D: 3@ = read_memory 0@ size 4 virtual_protect 0
if
3@ == FIRETYPE_INSTANT_HIT
then
0@ += 0x20 // CWeaponInfo.m_sMaxClipAmmo
0A8D: 4@ = read_memory 0@ size 2 virtual_protect 0
// 4@ will contain the maximum ammo in clip.
end
end
4@ is the maximum ammo count that the clip can contain.