Weapon.IsCarriedByLocalPlayer
From GMod Wiki
Function | |
Syntax | Weapon:IsCarriedByLocalPlayer( ) |
Description: | |
Returns true if the weapon is being carried by the local player. | |
Returns: | Boolean |
In Object: | Weapon |
Realm: | |
BBCode Link: | [b][url=http://wiki.garrysmod.com/?title=Weapon.IsCarriedByLocalPlayer]Weapon.IsCarriedByLocalPlayer [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b] |
Examples
Additional Notes
- This function is designed to run in functions that run on all clients simultaneously. This is used to determine if the client the function is running on is the one that is holding it.
- This is used as a condition for attaching effects to the viewmodel of the weapon instead of the world model often.