SWEP.Precache

From GMod Wiki

Revision as of 07:33, 9 November 2009 by Unrealomega (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Event Hook
Hook NamePrecache
SyntaxSWEP:Precache( )
DescriptionA function specifically for precaching materials and resources.
ReturnsNil
Lua StateNewerShared.png
BBCode[b][url=wiki.garrysmod.com/?title=SWEP.Precache]SWEP.Precache [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]

Example

DescriptionPrecaching the weapon's shoot sound.
Used onNewerShared.png
Code
 function SWEP:Precache() 
 	util.PrecacheSound( self.ShootSound ) 
 end 
OutputN/A

Additional Notes

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox