diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/core_constants.cpp | 4 | ||||
-rw-r--r-- | core/multiplayer/multiplayer.h | 4 | ||||
-rw-r--r-- | core/multiplayer/rpc_manager.cpp | 2 | ||||
-rw-r--r-- | core/object/object.cpp | 2 |
4 files changed, 6 insertions, 6 deletions
diff --git a/core/core_constants.cpp b/core/core_constants.cpp index 721e5ae622..b2d5a8fdf1 100644 --- a/core/core_constants.cpp +++ b/core/core_constants.cpp @@ -613,11 +613,11 @@ void register_global_constants() { // rpc BIND_CORE_ENUM_CONSTANT_CUSTOM("RPC_MODE_DISABLED", Multiplayer::RPC_MODE_DISABLED); - BIND_CORE_ENUM_CONSTANT_CUSTOM("RPC_MODE_ANY", Multiplayer::RPC_MODE_ANY); + BIND_CORE_ENUM_CONSTANT_CUSTOM("RPC_MODE_ANY_PEER", Multiplayer::RPC_MODE_ANY_PEER); BIND_CORE_ENUM_CONSTANT_CUSTOM("RPC_MODE_AUTH", Multiplayer::RPC_MODE_AUTHORITY); BIND_CORE_ENUM_CONSTANT_CUSTOM("TRANSFER_MODE_UNRELIABLE", Multiplayer::TRANSFER_MODE_UNRELIABLE); - BIND_CORE_ENUM_CONSTANT_CUSTOM("TRANSFER_MODE_ORDERED", Multiplayer::TRANSFER_MODE_ORDERED); + BIND_CORE_ENUM_CONSTANT_CUSTOM("TRANSFER_MODE_UNRELIABLE_ORDERED", Multiplayer::TRANSFER_MODE_UNRELIABLE_ORDERED); BIND_CORE_ENUM_CONSTANT_CUSTOM("TRANSFER_MODE_RELIABLE", Multiplayer::TRANSFER_MODE_RELIABLE); BIND_CORE_ENUM_CONSTANT_CUSTOM("TYPE_NIL", Variant::NIL); diff --git a/core/multiplayer/multiplayer.h b/core/multiplayer/multiplayer.h index 00c81d3c9a..31b7bf0043 100644 --- a/core/multiplayer/multiplayer.h +++ b/core/multiplayer/multiplayer.h @@ -39,13 +39,13 @@ namespace Multiplayer { enum TransferMode { TRANSFER_MODE_UNRELIABLE, - TRANSFER_MODE_ORDERED, + TRANSFER_MODE_UNRELIABLE_ORDERED, TRANSFER_MODE_RELIABLE }; enum RPCMode { RPC_MODE_DISABLED, // No rpc for this method, calls to this will be blocked (default) - RPC_MODE_ANY, // Any peer can call this RPC + RPC_MODE_ANY_PEER, // Any peer can call this RPC RPC_MODE_AUTHORITY, // / Only the node's multiplayer authority (server by default) can call this RPC }; diff --git a/core/multiplayer/rpc_manager.cpp b/core/multiplayer/rpc_manager.cpp index 915571375e..20ab7a25bb 100644 --- a/core/multiplayer/rpc_manager.cpp +++ b/core/multiplayer/rpc_manager.cpp @@ -99,7 +99,7 @@ _FORCE_INLINE_ bool _can_call_mode(Node *p_node, Multiplayer::RPCMode mode, int case Multiplayer::RPC_MODE_DISABLED: { return false; } break; - case Multiplayer::RPC_MODE_ANY: { + case Multiplayer::RPC_MODE_ANY_PEER: { return true; } break; case Multiplayer::RPC_MODE_AUTHORITY: { diff --git a/core/object/object.cpp b/core/object/object.cpp index 3335942fb3..b5797a4633 100644 --- a/core/object/object.cpp +++ b/core/object/object.cpp @@ -1409,7 +1409,7 @@ void Object::_disconnect(const StringName &p_signal, const Callable &p_callable, if (!p_force) { slot->reference_count--; // by default is zero, if it was not referenced it will go below it - if (slot->reference_count >= 0) { + if (slot->reference_count > 0) { return; } } |