Developer knowledge network ยท moderated exchange

UnreliableCode Community

Developer Research, Reverse Engineering & Coding Community

Knowledge indexLive
4Categories
919Threads
2.8KPosts
Analysis

Weapon hash table & component upgrade offset scanning in GTA V

fivem_native_coder
Lua Scripter
MEMBER
Rep: 64
Join Date: Jun 2019
Posts: 20
Thanks: 48
1 months ago ยท Jul 8, 2026 8:13 AM
#1

Finding weapon damage multipliers and ammo clips in memory:

  1. From CPed, read CWeaponManager at offset 0x10B8.
  2. From CWeaponManager, read CWeaponInfo for current weapon at offset 0x20.
  3. In CWeaponInfo:
    • fDamage (float at offset 0xB0)
    • fTimeBetweenShots (float at offset 0x134): Fire rate cooldown.
    • fReloadTimeMP (float at offset 0x138): Instant reload.
    • fRecoilShake (float at offset 0x2F4): Camera shake.
    • fSpread (float at offset 0x74): Bullet spread accuracy.

Setting fDamage = 1000.0f and fSpread = 0.0f gives instant 1-shot laser accuracy.

fivem_native_guru
CitizenFX Dev
MEMBER
Rep: 182
Join Date: May 2021
Posts: 8
Thanks: 69
1 months ago ยท Jul 8, 2026 9:26 AM
#2

Also modify fTimeBetweenShots to 0.05f to turn semi-auto pistols into full-auto miniguns.

ptr_arithmetic
C++ Wizard
MEMBER
Rep: 162
Join Date: May 2018
Posts: 73
Thanks: 42
1 months ago ยท Jul 8, 2026 4:32 PM
#3

Clean CWeaponInfo structure offsets.