# Delay replication for spectators

**URL:** <https://forums.unrealengine.com/t/delay-replication-for-spectators/381186>\
**Category:** Multiplayer & Networking\
**Tags:** dedicated-server, Replication, rts, spectator, unreal-engine, Multiplayer, question\
**Created:** [January 7, 2017, 3:38pm UTC](https://forums.unrealengine.com/t/delay-replication-for-spectators/381186 "2017-01-07T15:38:18Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_b467b02b](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_b467b02b](https://forums.unrealengine.com/u/anonymous_user_b467b02b)\
**Post date:** [January 7, 2017, 3:38pm UTC](https://forums.unrealengine.com/t/delay-replication-for-spectators/381186/1 "2017-01-07T15:38:18Z")

</div>

Hi,  
I couldn’t find any information how to delay replication to a client from a dedicated server in UE4, any1 knows of it even is possible within current functionality provided in 4.14?

I would like to have spectators in our RTS game running on a dedicated server, but with like 30 seconds delay.

Cheers!

---

<div class="post-metadata">

**Author:** ![nathan2022](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/nathan2022/32/596514_2.png) [@nathan2022](https://forums.unrealengine.com/u/nathan2022)\
**Post date:** [January 30, 2023, 10:41am UTC](https://forums.unrealengine.com/t/delay-replication-for-spectators/381186/2 "2023-01-30T10:41:01Z")

</div>

We are using UE4.27 to develop the MOBA project, and we are currently developing the function of watching the battle, which also requires the observer to have a certain delay in real time, do you have a solution

---

<div class="post-metadata">

**Author:** ![Chatouille](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/chatouille/32/1194622_2.png) [@Chatouille](https://forums.unrealengine.com/u/Chatouille)\
**Post date:** [January 30, 2023, 1:36pm UTC](https://forums.unrealengine.com/t/delay-replication-for-spectators/381186/3 "2023-01-30T13:36:12Z")

</div>

Your best bet is probably to rely on the replay system.

> **[Replay System](https://docs.unrealengine.com/4.27/en-US/TestingAndOptimization/ReplaySystem/)**
>
> Overview of the Replay system for recording and playback of gameplay

You can use/extend the NetworkReplayStreaming or HttpNetworkReplayStreaming module and connect it to your own server(s).

Epic provides a (supposedly working) streaming server implementation in java, available in engine source code :  
[https://github.com/EpicGames/UnrealEngine/tree/release/Engine/Source/Programs/ReplayServer](https://github.com/EpicGames/UnrealEngine/tree/release/Engine/Source/Programs/ReplayServer)

Pros of this approach :

- Watchers are not directly connected to the gameserver, they connect to the streaming server which can be focused more on bandwidth and less on performance. Reduces load for the gameserver.

- Data transfer is much more optimized, unlike video streaming - replay system uses builtin replication system, for the gameserver it’s essentially just like 1 additional spectator, then you can hook as many watchers as you want to the streaming server.

- You can definitely figure out a way to add arbitrary delay. If not on the gameserver side, you could do it on the streaming server or on the client replay module side.

- Replays can be saved to be watched later. System works exactly the same for saved replays and watching live games.

Cons :

- Requires streaming server(s) in addition to gameservers.

- Can be difficult/tedious to implement replication correctly to make stuff work as expected both in-game AND in-replay.

---

<div class="post-metadata">

**Author:** ![nathan2022](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/nathan2022/32/596514_2.png) [@nathan2022](https://forums.unrealengine.com/u/nathan2022)\
**Post date:** [February 16, 2023, 9:29am UTC](https://forums.unrealengine.com/t/delay-replication-for-spectators/381186/4 "2023-02-16T09:29:33Z")

</div>

Thanks for your answer.  
java implementation is too old that can not use.  
I rewrote a set of servers through the documentation and can use it
