How to Replicate Once Only On Initialization

I have a spawned object that only needs to have its initial location replicated to players. What’s the best way to implement this? When using the Replicates checkbox, it seems it still adds periodic pings for update throughout the game, which add up if there are a lot of objects replicating. I thought about having only one actor replicate and letting that spawn the objects, but then if a new player joins, they won’t see objects spawned in the past.

You could look into Replication conditions

In method GetLifetimeReplicatedProps you can call DOREPLIFETIME_CONDITION insteas of DOREPLIFETIME.

For example:
DOREPLIFETIME_CONDITION(AMyActor, MyActorPropertyForReplication, COND_InitialOnly);

More infor at: