• Infinite Ammo?
    6 replies, posted
Hey there, I am working on adding an infinite ammo script to my server, making everyone have unlimited ammo. Anybody know any easy methods?
The methods are: 1) Perfect, but unreasonable: Don't actually remove the ammo from the SWEP 2) Imperfect, but reasonable: SetClip1() and SetClip2 to max values in a timer.
Ah right, any like autorun code I could implement? Also, perfect person to reply, is it possible to buff the lightsaber lightning? As a matter of fact I am running a StarwarsRP server. :)
This isn't a make me forum. As for Lightsabers, you can always extract the Lua and edit it to your liking. Make sure not to redistribute edited copies, edited files will be automatically set to clients.
Ah right, thanks for your support! :)
[lua] function GIBAMMO() for k, v in pairs(player.GetAll()) do if v:IsPlayer() && !v:IsBot() then local wep = v:GetActiveWeapon() if IsValid(wep) then wep:SetClip1(100) end end end end hook.Add("Think", "PLSIBEGU", GIBAMMO) [/lua] Untested.
Alternatively, you can use [img]http://wiki.garrysmod.com/favicon.ico[/img] [url=http://wiki.garrysmod.com/page/GM/EntityFireBullets]GM/EntityFireBullets[/url] instead of Think hook for efficiency.
Sorry, you need to Log In to post a reply to this thread.