From bae843a1c9dadad2b40e17f1e44e13eb01d65f97 Mon Sep 17 00:00:00 2001 From: HaSa1002 Date: Sat, 28 Nov 2020 00:33:15 +0100 Subject: Docs: Port Code Examples to C# (R, S, T, U) * RenderingServer * RichTextEffect * SceneTree * SceneTreeTimer * ScriptCreateDialog * SpinBox * Sprite2D * StreamPeer * String * SurfaceTool * TextEdit * TileMap * Tree * Tween * UDPServer * UndoRedo Co-authored-by: Aaron Franke --- doc/classes/StreamPeer.xml | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'doc/classes/StreamPeer.xml') diff --git a/doc/classes/StreamPeer.xml b/doc/classes/StreamPeer.xml index a73d3c8212..a1b858acf6 100644 --- a/doc/classes/StreamPeer.xml +++ b/doc/classes/StreamPeer.xml @@ -212,9 +212,14 @@ 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] + [codeblocks] + [gdscript] put_data("Hello world".to_ascii()) - [/codeblock] + [/gdscript] + [csharp] + PutData("Hello World".ToAscii()); + [/csharp] + [/codeblocks] @@ -261,9 +266,14 @@ 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] + [codeblocks] + [gdscript] put_data("Hello world".to_utf8()) - [/codeblock] + [/gdscript] + [csharp] + PutData("Hello World".ToUTF8()); + [/csharp] + [/codeblocks] -- cgit v1.2.3