diff options
Diffstat (limited to 'doc/classes/MultiplayerPeerExtension.xml')
-rw-r--r-- | doc/classes/MultiplayerPeerExtension.xml | 43 |
1 files changed, 28 insertions, 15 deletions
diff --git a/doc/classes/MultiplayerPeerExtension.xml b/doc/classes/MultiplayerPeerExtension.xml index bd11c76039..18bc18e6e7 100644 --- a/doc/classes/MultiplayerPeerExtension.xml +++ b/doc/classes/MultiplayerPeerExtension.xml @@ -16,7 +16,7 @@ </description> </method> <method name="_get_connection_status" qualifiers="virtual const"> - <return type="int" /> + <return type="int" enum="MultiplayerPeer.ConnectionStatus" /> <description> Called when the connection status is requested on the [MultiplayerPeer] (see [method MultiplayerPeer.get_connection_status]). </description> @@ -28,11 +28,11 @@ </description> </method> <method name="_get_packet" qualifiers="virtual"> - <return type="int" /> - <argument index="0" name="r_buffer" type="const uint8_t **" /> - <argument index="1" name="r_buffer_size" type="int32_t*" /> + <return type="int" enum="Error" /> + <param index="0" name="r_buffer" type="const uint8_t **" /> + <param index="1" name="r_buffer_size" type="int32_t*" /> <description> - Called when a packet needs to be received by the [MultiplayerAPI], with [code]p_buffer_size[/code] being the size of the binary [code]p_buffer[/code] in bytes. + Called when a packet needs to be received by the [MultiplayerAPI], with [param r_buffer_size] being the size of the binary [param r_buffer] in bytes. </description> </method> <method name="_get_packet_peer" qualifiers="virtual const"> @@ -41,6 +41,12 @@ Called when the ID of the [MultiplayerPeer] who sent the most recent packet is requested (see [method MultiplayerPeer.get_packet_peer]). </description> </method> + <method name="_get_packet_script" qualifiers="virtual"> + <return type="PackedByteArray" /> + <description> + Called when a packet needs to be received by the [MultiplayerAPI], if [method _get_packet] isn't implemented. Use this when extending this class via GDScript. + </description> + </method> <method name="_get_transfer_channel" qualifiers="virtual const"> <return type="int" /> <description> @@ -48,7 +54,7 @@ </description> </method> <method name="_get_transfer_mode" qualifiers="virtual const"> - <return type="int" /> + <return type="int" enum="MultiplayerPeer.TransferMode" /> <description> Called when the transfer mode to use is read on this [MultiplayerPeer] (see [member MultiplayerPeer.transfer_mode]). </description> @@ -72,43 +78,50 @@ </description> </method> <method name="_poll" qualifiers="virtual"> - <return type="int" /> + <return type="void" /> <description> Called when the [MultiplayerAPI] is polled. See [method MultiplayerAPI.poll]. </description> </method> <method name="_put_packet" qualifiers="virtual"> - <return type="int" /> - <argument index="0" name="p_buffer" type="const uint8_t*" /> - <argument index="1" name="p_buffer_size" type="int" /> + <return type="int" enum="Error" /> + <param index="0" name="p_buffer" type="const uint8_t*" /> + <param index="1" name="p_buffer_size" type="int" /> + <description> + Called when a packet needs to be sent by the [MultiplayerAPI], with [param p_buffer_size] being the size of the binary [param p_buffer] in bytes. + </description> + </method> + <method name="_put_packet_script" qualifiers="virtual"> + <return type="int" enum="Error" /> + <param index="0" name="p_buffer" type="PackedByteArray" /> <description> - Called when a packet needs to be sent by the [MultiplayerAPI], with [code]p_buffer_size[/code] being the size of the binary [code]p_buffer[/code] in bytes. + Called when a packet needs to be sent by the [MultiplayerAPI], if [method _put_packet] isn't implemented. Use this when extending this class via GDScript. </description> </method> <method name="_set_refuse_new_connections" qualifiers="virtual"> <return type="void" /> - <argument index="0" name="p_enable" type="bool" /> + <param index="0" name="p_enable" type="bool" /> <description> Called when the "refuse new connections" status is set on this [MultiplayerPeer] (see [member MultiplayerPeer.refuse_new_connections]). </description> </method> <method name="_set_target_peer" qualifiers="virtual"> <return type="void" /> - <argument index="0" name="p_peer" type="int" /> + <param index="0" name="p_peer" type="int" /> <description> Called when the target peer to use is set for this [MultiplayerPeer] (see [method MultiplayerPeer.set_target_peer]). </description> </method> <method name="_set_transfer_channel" qualifiers="virtual"> <return type="void" /> - <argument index="0" name="p_channel" type="int" /> + <param index="0" name="p_channel" type="int" /> <description> Called when the channel to use is set for this [MultiplayerPeer] (see [member MultiplayerPeer.transfer_channel]). </description> </method> <method name="_set_transfer_mode" qualifiers="virtual"> <return type="void" /> - <argument index="0" name="p_mode" type="int" /> + <param index="0" name="p_mode" type="int" enum="MultiplayerPeer.TransferMode" /> <description> Called when the transfer mode is set on this [MultiplayerPeer] (see [member MultiplayerPeer.transfer_mode]). </description> |