General > Developers Corner

How to request default clip size

(1/1)

Bite That Apple:
Question is in title, how do I get the default clip size for a swep?

JamminR:
Theorizing;
weapon.Get = http://wiki.garrysmod.com/page/weapons/Get - Using classname of the swep to grab table info.
Think it would return a table of the items listed here - http://wiki.garrysmod.com/page/Structures/SWEP
Within that table is yet one more table called Primary that contains default ammo, and another called Secondary containing default ammo.

Bite That Apple:
Though I already replied to this. Thank you, I got it to work, except with non-swep... I don't understand why Garry just doesn't remake them.. they can so many problems with Garry's Mod.

Navigation

[0] Message Index

Go to full version