Description

It seems as though calling a multicast RPC during BeginPlay on the server will cause the new actor to finish spawning on the client before applying any initial replicated data, such as the actor's Role.
When first connecting, the pawn's role will be correct during its BeginPlay on the client, perhaps due to the initial BeginPlay being dispatched from AGameStateBase::OnRep_ReplicatedHasBegunPlay on the client.
The reliability of the multicast did not appear to affect the behavior, and the issue does not seem to occur when calling a client RPC.

Steps to Reproduce

Create a pawn where the server calls a multicast RPC (either reliable or unreliable) from its BeginPlay. Have the server then destroy and restart a player's pawn.
Expected: the client that owns the pawn will call BeginPlay with a role of autonomous proxy
Actual: the pawn's role during BeginPlay will be simulated proxy

See linked UDN for more info.

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-155934 in the post.

2
Login to Vote

Backlogged
ComponentUE - Networking
Affects Versions5.0
CreatedJun 6, 2022
UpdatedSep 28, 2022