[Net] Modularize multiplayer, expose MultiplayerAPI to extensions.

- RPC configurations are now dictionaries.
- Script.get_rpc_methods renamed to Script.get_rpc_config.
- Node.rpc[_id] and Callable.rpc now return an Error.
- Refactor MultiplayerAPI to allow extension.
- New MultiplayerAPI.rpc method with Array argument (for scripts).
- Move the default MultiplayerAPI implementation to a module.
This commit is contained in:
Fabio Alessandrelli 2022-07-12 23:12:42 +02:00
parent c3dc887c41
commit ca7d572908
80 changed files with 1819 additions and 1388 deletions

View file

@ -1975,7 +1975,7 @@ GDScriptFunction *GDScriptCompiler::_parse_function(Error &r_error, GDScript *p_
StringName func_name;
bool is_static = false;
Multiplayer::RPCConfig rpc_config;
Variant rpc_config;
GDScriptDataType return_type;
return_type.has_type = true;
return_type.kind = GDScriptDataType::BUILTIN;