weapons/GetStored

From Garry's Mod
(Difference between revisions)
Jump to: navigation, search
m (Forgot return value)
(Make note of differences compared to wepaons.Get. Added a warning to clarify what the consequences of a "real" table is.)
 
Line 1: Line 1:
 
{{Func
 
{{Func
|Name=GetStored
+
|Description=Gets the REAL weapon table, not a copy. The produced table does ''not'' inherit fields from the weapon's base class, unlike {{LibraryFunction|weapons|Get}}.
|Parent=weapons
+
 
|Description=Gets the REAL weapon table, not a copy.
+
{{Warning|Modifying this table will modify what is stored by the weapons library. Take a copy or use {{LibraryFunction|weapons|Get}} to avoid this.}}
 
|Realm=Shared
 
|Realm=Shared
 
|IsClass=No
 
|IsClass=No

Latest revision as of 12:18, 9 May 2019

 weapons.GetStored( )

Description

Gets the REAL weapon table, not a copy. The produced table does not inherit fields from the weapon's base class, unlike weapons.Get.

WARNING

Modifying this table will modify what is stored by the weapons library. Take a copy or use weapons.Get to avoid this.

Arguments

string weapon_class

Weapon class to retrieve weapon table of

Returns

table

The weapon table
Personal tools
Navigation