G.AccessorFunc
From GMod Wiki
Function | |
Syntax |
AccessorFunc( Table tab, String varname, String name[, Integer iForce] ) Where is this used? |
Description: | |
Quickly make Get/Set accessor fuctions on the specified table | |
Returns: | nil |
Part of Library: | Global Functions |
Realm: | |
BBCode Link: | [b][url=http://wiki.garrysmod.com/?title=G.AccessorFunc]G.AccessorFunc [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b] |
Examples
Additional Notes
- This function creates two new functions on the table you deliver which simply do nothing else but setting a variable to another value.
- If you set the iForce argument then it will forcefully return a value of that type.
- To use, FORCE_* (Where * is the enum below)
SHARED | 0000000000000001 | 00000000000000001 | STRING SHARED | 0000000000000002 | 00000000000000010 | NUMBER SHARED | 0000000000000003 | 00000000000000011 | BOOL