Weapon

From GMod Wiki

Revision as of 19:08, 18 June 2011 by Donkie (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Weapon is the object of the... weapon a player or npc is holding.

It can be accessed through self in a swep script, or by ply:GetActiveWeapon().

The Weapon object is a child of Entity.

Object Methods

NewerShared.png Weapon:CallOnClient
NewerShared.png Weapon:Clip1
NewerShared.png Weapon:Clip2
NewerShared.png Weapon:DefaultReload
NewerShared.png Weapon:GetActivity
NewerShared.png Weapon:GetNextPrimaryFire
NewerShared.png Weapon:GetNextSecondaryFire
NewerShared.png Weapon:GetPrimaryAmmoType
NewerShared.png Weapon:GetSecondaryAmmoType
NewerShared.png Weapon:IsNPC
NewerShared.png Weapon:IsPlayer
NewerShared.png Weapon:IsVehicle
NewerShared.png Weapon:IsWeapon
NewerShared.png Weapon:IsWeaponVisible
NewerShared.png Weapon:LastShootTime
NewerShared.png Weapon:SendWeaponAnim
NewerShared.png Weapon:SetClip1
NewerShared.png Weapon:SetClip2
NewerShared.png Weapon:SetNextPrimaryFire
NewerShared.png Weapon:SetNextSecondaryFire
NewerShared.png Weapon:SetWeaponHoldType
NewerClient.png Weapon.GetPrintName
NewerClient.png Weapon.IsCarriedByLocalPlayer

See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox