This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
functions:sendstring [2016/10/18 20:58] – [Sending strings] korshun | functions:sendstring [2016/10/19 00:24] – korshun | ||
---|---|---|---|
Line 3: | Line 3: | ||
===== Sending strings ===== | ===== Sending strings ===== | ||
'' | '' | ||
+ | |||
'' | '' | ||
Line 12: | Line 13: | ||
</ | </ | ||
- | <note warning> | + | Maximum string size is unlimited, but the larger it is, the more the server will lag while sending it. |
- | <note warning> | + | |
+ | <note warning> | ||
Test your mods on a server (this is recommended for many other reasons too).</ | Test your mods on a server (this is recommended for many other reasons too).</ | ||
Line 25: | Line 27: | ||
script 123 (int a, int b, int c, int d) CLIENTSIDE | script 123 (int a, int b, int c, int d) CLIENTSIDE | ||
{ | { | ||
- | // Do nothing if the string hasn't been fully received. | ||
if (!ReceiveString(a, | if (!ReceiveString(a, | ||
terminate; | terminate; | ||
- | // The string | + | // Insert your code here. The string can now be retrieved using GetReceivedString(). |
Log(s:" | Log(s:" | ||
} | } |