G.SetGlobalString
From GMod Wiki
Revision as of 14:37, 3 August 2011 by ClavusElite (Talk | contribs)
Function | |
Syntax |
SetGlobalString( Var index, String value ) Where is this used? |
Description: | |
Similiar to the function Entity:SetNetworkedString - Sets a networked String , but outside of the entity. | |
Returns: | nil |
Part of Library: | Global Functions |
Realm: | |
BBCode Link: | [b][url=http://wiki.garrysmod.com/?title=G.SetGlobalString]G.SetGlobalString [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b] |
Examples
Additional Notes
- Running a networked function will cause it to synchronize the networked data with the clients.
- Index can be a String or Integer - however, when dealing with global networked variables, it's suggested that you use a string with part of the name of your script in it - like "mygamemode_tickrate", for example.
- Running this function clientside will only set it clientside - not serverside.
- Only set networked variables when necessary - sending networked variables constantly is expensive.
- The string length seems to be capped at 199 characters