My timeline executes reversed, but my activition timer doesn't.

Hey everyone!

I have created a VR raytracing system by following a tutorial.
Everything works fine, but I want to create something that I just can’t figure out.

I’ve got three raytrace events. One executes on focus (OnFocus), one activates on defocus (OnBlur) and the other one executes after 3 seconds (OnActivate). The three seconds time window is defined by the GetFocusTimeActive.

At the moment, whenever the player looks at the cube (OnFocus), the cube scales. Whenever the player defocus (OnBlur) the timeline is reversed and the cube gets smaller. And after three seconds of looking at the cube, the cube turns red (OnActive).

There is one problem however. The 3 seconds timer is set to 0 seconds on defocus, but the cube is still scaling down. How can I synchronise the timer and the scaling cube? So whenever the cubes timeline is at 50%, the GetFocusTimeActive is at 1.5 seconds.

Thanks in advance and have a nice day!

What if you make a timer manually? Set a float variable and increase it by delta seconds with each tick when the timeline plays forward, and decrease it by the same delta seconds when the timeline plays backwards.

Add a float track to your timeline that goes linearly from 0 to 3. Output that float from the timeline to sync everything.