godotengine / godot-docs

Godot Engine official documentation
https://docs.godotengine.org
Other
3.94k stars 3.22k forks source link

Add explicit definitions for remote, remotesync, master, and puppet keywords #3917

Closed ZackingIt closed 1 year ago

ZackingIt commented 4 years ago

Your Godot version: 3.22

Issue description: Please consider re-writing the master/puppet/remote/remotesync RPC documentation? All that is done is referencing a Bomberman example without actually documenting what each keyword literally does in an explicit and technical way.

URL to the documentation page (if already existing): https://docs.godotengine.org/en/stable/tutorials/networking/high_level_multiplayer.html

Right now, the only explicit text is very vague: "The remote keyword means that the rpc() call will go via network and execute remotely.

The remotesync keyword means that the rpc() call will go via network and execute remotely, but will also execute locally (do a normal function call)."

There are no explicit definitions of master and puppet -- we are asked to define them ourselves only by the context/use provided.

Elektron72 commented 4 years ago

There is also no description of what these keywords do when applied to variables.

Calinou commented 4 years ago

cc @Faless

Faless commented 4 years ago

A more verbose description is available here: https://docs.godotengine.org/en/3.2/classes/class_multiplayerapi.html#enumerations

I don't know where's the best place to document the keyword.

nathanfranke commented 2 years ago

Hey Zack, this is a pretty old issue but note that these keywords have changed in Godot 4 to be way more readable.

@rpc(any_peer) - rpc that any peer can call @rpc(authority) - rpc that only the network authority can call @rpc(any_peer, call_local) - rpc that any peer can call, also calls locally @rpc(authority, call_local) - rpc that only the network authority can call, also calls locally

YuriSizov commented 2 years ago

In Godot 4 we also have annotations in the class reference where they can (and will) be documented independently from the existing tutorials.

But the question is, is this issue still valid for 3.x documentation?

nathanfranke commented 2 years ago

Yeah, I've always been confused by this. Considering how many users will be using 3.5, updating this documentation will still be useful. PR made :smiley:

mhilbrunner commented 1 year ago

Closing as done by the above PR; the multiplayer docs are in the process of being reworked for 4.0.