Search Issue Tracker
By Design
Votes
0
Found in
2019.4
2020.3
2021.1
2021.1.3f1
2021.2
2022.1
Issue ID
1343845
Regression
No
PlayableBehaviour.PrepareFrame ignores Time.timeScale when Time.timeScale value does not equal 0 or 1
Steps to reproduce:
1. Open the attached project "Project.zip"
2. Open Scenes/SampleScene
3. Enter the Play Mode
4. Observe the Console window
Expected result: info.deltaTime value equals Time.deltaTime value
Actual result: Time.deltaTime value is 10 times higher than info.deltaTime
Reproducible with: 2019.4.29f1, 2020.3.16f1, 2021.1.17f1, 2021.2.0b7, 2022.1.0a5
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Memory leak occurs when focused on Player while using Direct3D12
- var VisionOSEDRHeadromm has a comma instead of a dot when building with Metal Rendering App Mode and local OS localization is set to German
- IAP Catalog remove product “x” and add product “+” buttons are not consistent with other remove and add buttons in the Editor
- Performance issues in Play Mode when quickly hovering the mouse cursor over Hierarchy GameObjects
- Frame Debugger displays incorrect output when FidelityFX Super Resolution or Spatial-Temporal Upscaler is used with Temporal Anti-aliasing or Subpixel Morphological Anti-aliasing
Resolution Note:
FrameData's deltaTime is unscaled by design. Its scaling is different depending on the DirectorUpdateMode. Sometimes Time.timeScale is accounted for, sometimes it's not, depending on the mode. Moreover, nodes in the playable graph can have non-unit speeds, that also change the scale of a particular node's deltaTime (if itself or an ancestor has a non-unit speed). As such, the FrameData's deltaTime should be multiplied by its effectiveSpeed to get the correctly scaled value.
However it's true that the naming is not consistent with Time.deltaTime. Unfortunately, changing the public API is highly risky, as a lot of people may already rely on it. We're going to update the documentation to at least bring to attention that FrameData.deltaTime is unscaled and should be multiplied by effectiveSpeed if the scaling is needed.