# \[Somewhat-Solved\] How do I get the current time in my replay?

**URL:** <https://forums.unrealengine.com/t/somewhat-solved-how-do-i-get-the-current-time-in-my-replay/458770>\
**Category:** Blueprint\
**Tags:** timeline, demo, replay, unreal-engine, Blueprint, question\
**Created:** [November 25, 2019, 2:17pm UTC](https://forums.unrealengine.com/t/somewhat-solved-how-do-i-get-the-current-time-in-my-replay/458770 "2019-11-25T14:17:39Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Capn\_C4ke](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/capn_c4ke/32/1194596_2.png) [@Capn\_C4ke](https://forums.unrealengine.com/u/Capn_C4ke)\
**Post date:** [November 25, 2019, 2:17pm UTC](https://forums.unrealengine.com/t/somewhat-solved-how-do-i-get-the-current-time-in-my-replay/458770/1 "2019-11-25T14:17:39Z")

</div>

Hi, I’m currently trying to get the current time in my replay, so that I can set a slider bar to that value, and I can have a “-10” and a “+10” button to go 10 seconds behind and forward in my replay. I am working in blueprints, and right now, I am using “execute console command” for other functions like demopause. Please Help!!

---

<div class="post-metadata">

**Author:** ![TRI99ER](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TRI99ER](https://forums.unrealengine.com/u/TRI99ER)\
**Post date:** [November 26, 2019, 3:33pm UTC](https://forums.unrealengine.com/t/somewhat-solved-how-do-i-get-the-current-time-in-my-replay/458770/2 "2019-11-26T15:33:30Z")

</div>

To get current time you need to get a global variable called [World Delta Seconds](https://docs.unrealengine.com/en-US/BlueprintAPI/Utilities/Time/GetWorldDeltaSeconds/index.html).  
Its a float variable holding time in seconds.

---

<div class="post-metadata">

**Author:** ![Capn\_C4ke](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/capn_c4ke/32/1194596_2.png) [@Capn\_C4ke](https://forums.unrealengine.com/u/Capn_C4ke)\
**Post date:** [November 26, 2019, 8:23pm UTC](https://forums.unrealengine.com/t/somewhat-solved-how-do-i-get-the-current-time-in-my-replay/458770/3 "2019-11-26T20:23:32Z")

</div>

Thanks, Now how do I get my replay total length? I need to be able to divide my current time by my length to determine the percent of the replay I am at

---

<div class="post-metadata">

**Author:** ![TRI99ER](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TRI99ER](https://forums.unrealengine.com/u/TRI99ER)\
**Post date:** [December 9, 2019, 2:32pm UTC](https://forums.unrealengine.com/t/somewhat-solved-how-do-i-get-the-current-time-in-my-replay/458770/4 "2019-12-09T14:32:05Z")

</div>

You need to store it in variable inside persistent object (like Game Instance). Basically, when you play, keep track of time and update total time played (you need to add Delta Seconds every tick to that variable (or, you can assign World Delta Seconds to it at the end of play session, it will contain total time)), and then when you watch replay, just get value of that variable. And if you gonna save replays you need to save it too.

---

<div class="post-metadata">

**Author:** ![Capn\_C4ke](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/capn_c4ke/32/1194596_2.png) [@Capn\_C4ke](https://forums.unrealengine.com/u/Capn_C4ke)\
**Post date:** [December 9, 2019, 11:24pm UTC](https://forums.unrealengine.com/t/somewhat-solved-how-do-i-get-the-current-time-in-my-replay/458770/5 "2019-12-09T23:24:16Z")

</div>

Ok, thanks. I was thinking of making a save game object with an array of custom structures, and then calling variables from those. Thanks for the help, That simple answer helped alot!!!

---

<div class="post-metadata">

**Author:** ![TRI99ER](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TRI99ER](https://forums.unrealengine.com/u/TRI99ER)\
**Post date:** [December 10, 2019, 3:37pm UTC](https://forums.unrealengine.com/t/somewhat-solved-how-do-i-get-the-current-time-in-my-replay/458770/6 "2019-12-10T15:37:07Z")

</div>

Sorry it took so long. Wasn’t able to reply sooner. If you consider Question solved, no need to write it in title, just check the mark left to any answer you feel helped you.
