mirror of
https://github.com/godotengine/godot
synced 2024-09-05 17:59:56 +00:00
![Fabio Alessandrelli](/assets/img/avatar_default.png)
Adds a OfflineMultiplayerPeer class which behaves like a server with no connected peers. Use OfflineMultiplayerPeer as default for SceneMultiplayer. This means that the SceneTree will act as the multiplayer authority by default. Calls to is_server will return true, and calls to get_unique_id will return TARGET_PEER_SERVER.
13 lines
824 B
XML
13 lines
824 B
XML
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<class name="OfflineMultiplayerPeer" inherits="MultiplayerPeer" version="4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
|
|
<brief_description>
|
|
A [MultiplayerPeer] which is always connected and acts as a server.
|
|
</brief_description>
|
|
<description>
|
|
This is the default [member MultiplayerAPI.multiplayer_peer] for the [member Node.multiplayer]. It mimics the behavior of a server with no peers connected.
|
|
This means that the [SceneTree] will act as the multiplayer authority by default. Calls to [method MultiplayerAPI.is_server] will return [code]true[/code], and calls to [method MultiplayerAPI.get_unique_id] will return [constant MultiplayerPeer.TARGET_PEER_SERVER].
|
|
</description>
|
|
<tutorials>
|
|
</tutorials>
|
|
</class>
|