Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- For Unlimited ammo --
- function GetRequiredVersion()
- return 200
- end
- function OnScriptLoad(processid, game, persistent) end
- function OnPlayerSpawnEnd(player, m_objectId)
- registertimer(1000, "InfiniteAmmo", player)
- end
- function InfiniteAmmo(id, count, player)
- local m_player = getplayer(player)
- if m_player then
- local objId = readdword(m_player, 0x34)
- local m_object = getobject(objId)
- if m_object then
- for i = 0,3 do
- local weapId = readdword(m_object, 0x2F8 + (i * 4))
- local m_weapon = getobject(weapId)
- if m_weapon then
- writeword(m_weapon, 0x2B6, 9999)
- writeword(m_weapon, 0x2B8, 9999)
- updateammo(weapId)
- end
- end
- return true
- end
- end
- return false
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement