Merge pull request #63262 from dsnopek/multiplayer-peer-custom-4.x
[4.x] Allow extending MultiplayerPeerExtension from GDScript
This commit is contained in:
commit
75f93167f7
3 changed files with 46 additions and 0 deletions
|
|
@ -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>
|
||||
|
|
@ -85,6 +91,13 @@
|
|||
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.
|
||||
</description>
|
||||
</method>
|
||||
<method name="_put_packet_script" qualifiers="virtual">
|
||||
<return type="int" />
|
||||
<argument index="0" name="p_buffer" type="PackedByteArray" />
|
||||
<description>
|
||||
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" />
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue