Entity.SetUseType
From GMod Wiki
Function | |
Syntax | Entity:SetUseType( Integer usetype ) |
Description: | |
Sets the entity's usetype. It takes an integer that corresponds to a usetype enumeration. | |
Returns: | nil |
In Object: | Entity |
Realm: | |
BBCode Link: | [b][url=http://wiki.garrysmod.com/?title=Entity.SetUseType]Entity.SetUseType [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b] |
Examples
Description | Makes the ENT.Use hook only get called once at every use. |
---|---|
Used on | |
Code | Entity:SetUseType(SIMPLE_USE) |
Output | N/A |
Additional Notes
These are the states that a button can be:
SHARED | 0000000000000000 | 00000000000000000 | CONTINUOUS_USE - Default, like a charger. SHARED | 0000000000000001 | 00000000000000001 | ONOFF_USE - Toggling true/false use. SHARED | 0000000000000002 | 00000000000000010 | DIRECTIONAL_USE - Like a wheel turning. SHARED | 0000000000000003 | 00000000000000011 | SIMPLE_USE - Single press.