diff --git a/doc/classes/DTLSServer.xml b/doc/classes/DTLSServer.xml index f4c75a731d8..41e241779a9 100644 --- a/doc/classes/DTLSServer.xml +++ b/doc/classes/DTLSServer.xml @@ -45,7 +45,7 @@ { private DtlsServer _dtls = new DtlsServer(); private UdpServer _server = new UdpServer(); - private Godot.Collections.Array<PacketPeerDTLS> _peers = new Godot.Collections.Array<PacketPeerDTLS>(); + private Godot.Collections.Array<PacketPeerDtls> _peers = new Godot.Collections.Array<PacketPeerDtls>(); public override void _Ready() { @@ -59,8 +59,8 @@ { while (Server.IsConnectionAvailable()) { - PacketPeerUDP peer = _server.TakeConnection(); - PacketPeerDTLS dtlsPeer = _dtls.TakeConnection(peer); + PacketPeerUdp peer = _server.TakeConnection(); + PacketPeerDtls dtlsPeer = _dtls.TakeConnection(peer); if (dtlsPeer.GetStatus() != PacketPeerDtls.Status.Handshaking) { continue; // It is normal that 50% of the connections fails due to cookie exchange. diff --git a/doc/classes/HTTPClient.xml b/doc/classes/HTTPClient.xml index 25b6a48283f..b6007a3b6b6 100644 --- a/doc/classes/HTTPClient.xml +++ b/doc/classes/HTTPClient.xml @@ -156,9 +156,9 @@ [/gdscript] [csharp] var fields = new Godot.Collections.Dictionary { { "username", "user" }, { "password", "pass" } }; - string queryString = new HTTPClient().QueryStringFromDict(fields); + string queryString = new HttpClient().QueryStringFromDict(fields); string[] headers = { "Content-Type: application/x-www-form-urlencoded", $"Content-Length: {queryString.Length}" }; - var result = new HTTPClient().Request(HTTPClient.Method.Post, "index.php", headers, queryString); + var result = new HttpClient().Request(HttpClient.Method.Post, "index.php", headers, queryString); [/csharp] [/codeblocks] [b]Note:[/b] The [param body] parameter is ignored if [param method] is [constant HTTPClient.METHOD_GET]. This is because GET methods can't contain request data. As a workaround, you can pass request data as a query string in the URL. See [method String.uri_encode] for an example. diff --git a/doc/classes/HTTPRequest.xml b/doc/classes/HTTPRequest.xml index 03c1ce2e001..6efa675a71e 100644 --- a/doc/classes/HTTPRequest.xml +++ b/doc/classes/HTTPRequest.xml @@ -43,7 +43,7 @@ public override void _Ready() { // Create an HTTP request node and connect its completion signal. - var httpRequest = new HTTPRequest(); + var httpRequest = new HttpRequest(); AddChild(httpRequest); httpRequest.RequestCompleted += HttpRequestCompleted; @@ -61,7 +61,7 @@ { { "name", "Godette" } }); - error = httpRequest.Request("https://httpbin.org/post", null, HTTPClient.Method.Post, body); + error = httpRequest.Request("https://httpbin.org/post", null, HttpClient.Method.Post, body); if (error != Error.Ok) { GD.PushError("An error occurred in the HTTP request."); @@ -115,7 +115,7 @@ public override void _Ready() { // Create an HTTP request node and connect its completion signal. - var httpRequest = new HTTPRequest(); + var httpRequest = new HttpRequest(); AddChild(httpRequest); httpRequest.RequestCompleted += HttpRequestCompleted; @@ -130,7 +130,7 @@ // Called when the HTTP request is completed. private void HttpRequestCompleted(long result, long responseCode, string[] headers, byte[] body) { - if (result != (long)HTTPRequest.Result.Success) + if (result != (long)HttpRequest.Result.Success) { GD.PushError("Image couldn't be downloaded. Try a different image."); } diff --git a/doc/classes/InputEventMIDI.xml b/doc/classes/InputEventMIDI.xml index 0f0b7566512..4dcaf987473 100644 --- a/doc/classes/InputEventMIDI.xml +++ b/doc/classes/InputEventMIDI.xml @@ -37,13 +37,13 @@ public override void _Input(InputEvent inputEvent) { - if (inputEvent is InputEventMIDI midiEvent) + if (inputEvent is InputEventMidi midiEvent) { PrintMIDIInfo(midiEvent); } } - private void PrintMIDIInfo(InputEventMIDI midiEvent) + private void PrintMIDIInfo(InputEventMidi midiEvent) { GD.Print(midiEvent); GD.Print($"Channel {midiEvent.Channel}"); diff --git a/doc/classes/PCKPacker.xml b/doc/classes/PCKPacker.xml index 2627c8b7d3e..494e9966ac9 100644 --- a/doc/classes/PCKPacker.xml +++ b/doc/classes/PCKPacker.xml @@ -13,7 +13,7 @@ packer.flush() [/gdscript] [csharp] - var packer = new PCKPacker(); + var packer = new PckPacker(); packer.PckStart("test.pck"); packer.AddFile("res://text.txt", "text.txt"); packer.Flush(); diff --git a/doc/classes/PacketPeerUDP.xml b/doc/classes/PacketPeerUDP.xml index 41457761fd9..12d3178797a 100644 --- a/doc/classes/PacketPeerUDP.xml +++ b/doc/classes/PacketPeerUDP.xml @@ -121,7 +121,7 @@ return [/gdscript] [csharp] - var socket = new PacketPeerUDP(); + var socket = new PacketPeerUdp(); // Server socket.SetDestAddress("127.0.0.1", 789); socket.PutPacket("Time to stop".ToAsciiBuffer());