How do I make my own ammo type? Such as instead of using "pistol" I would use my own ammo type so that they do not same the same ammo.
You could set it to "none" and make up your own value in the SWEP table. Then you can make a SENT to act as the physical ammo.
Cool thanks.
You could also use these more obscure ammo types (CombineCannon, SniperPenetratedRound) and shit that nobody else really uses for their SWEPs. Along with that, instead of having them named CombineCannon and what not, you can re-name them (so that when you pick weapons up off the ground and shit it doesn't say [40 - CombineCannon]) using the language.Add syntax.
It'll work as follows (remember to whack it in a client side lua file)
[lua]
language.Add("sniperpenetratedround_ammo", ".45 ACP")
[/lua]
Will display any ammo picked up that is SniperPenetratedAmmo as .45 ACP ammo.
You can do the same for the default ammo types, i.e. pistol, buckshot and smg. Same way.
[lua]
language.Add("pistol_ammo", "9x19mm Parabellum")
[/lua]
Every time you pick up some pistol ammo now, it will display the amount you picked up plus 9x19mm Parabellum next to it on your HUD.
That's just a different way, and possibly easier, depending on what you need this for exactly.
Woops, forgot to show you where you can find a list of the ammo types. Right [b][url=http://wiki.garrysmod.com/?title=Ammo_type]here[/url][/b] my friend.
Thanks man, this looks easier.
Sorry, you need to Log In to post a reply to this thread.