Skip to content

Silent RPC failure? #3989

Description

@zachstronaut

Description

We have confirmed a ServerRPC being invoked on a Client and never invoking on the Host+Server through a Log immediately before calling the ServerRPC on the client and a Log inside the ServerRPC on the server. We didn't have log levels set to Developer at the time we captured this happening, so we're unsure the cause or if the higher log level would have perhaps mentioned something. This was in Netcode 2.7.0. It seems to happen rarely when additively loading the next game level, perhaps when loading that level is slow. The ServerRPC in question lives on a NetworkObject in a scene that never gets unloaded.

But also, I noticed that in RpcMessages.cs in all Netcode versions through 2.11.2 the Deserialize method has what look like two silent failures. Are these in fact potential silent failures?

varnetworkObject=networkManager.SpawnManager.SpawnedObjects[metadata.NetworkObjectId];varnetworkBehaviour=networkManager.SpawnManager.SpawnedObjects[metadata.NetworkObjectId].GetNetworkBehaviourAtOrderIndex(metadata.NetworkBehaviourId);if(networkBehaviour==null){returnfalse;}if(!NetworkBehaviour.__rpc_func_table[networkBehaviour.GetType()].ContainsKey(metadata.NetworkRpcMethodId)){returnfalse;}

Environment

  • OS: Windows
  • Unity Version: 6000.1.17f1
  • Netcode Version: see above
  • Netcode Topology: Client-Server

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

stat:importedStatus - Issue is tracked internally at Unitytype:bugBug Report

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions