mirror of https://github.com/godotengine/godot
doc: Add note about sending strings without size in StreamPeer
Follow-up to #29153.
This commit is contained in:
parent
b177051521
commit
caa88b4611
|
|
@ -211,6 +211,10 @@
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Puts a zero-terminated ASCII string into the stream prepended by a 32-bit unsigned integer representing its size.
|
Puts a zero-terminated ASCII string into the stream prepended by a 32-bit unsigned integer representing its size.
|
||||||
|
Note: To put an ASCII string without prepending its size, you can use [method put_data]:
|
||||||
|
[codeblock]
|
||||||
|
put_data("Hello world".to_ascii())
|
||||||
|
[/codeblock]
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="put_u16">
|
<method name="put_u16">
|
||||||
|
|
@ -256,6 +260,10 @@
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Puts a zero-terminated UTF-8 string into the stream prepended by a 32 bits unsigned integer representing its size.
|
Puts a zero-terminated UTF-8 string into the stream prepended by a 32 bits unsigned integer representing its size.
|
||||||
|
Note: To put an UTF-8 string without prepending its size, you can use [method put_data]:
|
||||||
|
[codeblock]
|
||||||
|
put_data("Hello world".to_utf8())
|
||||||
|
[/codeblock]
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="put_var">
|
<method name="put_var">
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue