Garry's Mod Wiki

Revision Difference

Calling_net.Start_with_unpooled_message_name#514064

<cat>Dev</cat>⤶ When calling net.Start the message name should be pooled. This means that instead of sending the string over the network - it will be able to send a number representing the string.⤶ ⤶ To pool a string you need to call ⤶ ```⤶ util.AddNetworkString( "string" )⤶ ```⤶ serverside before trying to send the message. Ideally you'd do this when your Lua files are being loaded - but where that's not possible you need to do it at least a couple of seconds before calling the message to be sure that it'll work.⤶ ⤶ <page>util.AddNetworkString</page> only needs to be called once - and can only be called serverside.⤶ ⤶