fixedDeltaTime
The interval in seconds of in-game time at which physics and other fixed frame rate updates (like MonoBehaviour's MonoBehaviour.FixedUpdate() ) are performed.
Read time 1 minuteLast updated 6 days ago
Definition
- Type: Property
- Namespace: UnityEngine
- Assembly: UnityEngine.CoreModule
public static float fixedDeltaTime { get; set; }
Remarks
The interval is always relative to the in-game time which Time.timeScale affects. A of 1 second in a game with a Time.timeScale of 0.5 means fixed updates occur every 2 seconds of real time.
fixedDeltaTimefixedDeltaTimeNote: To support high-precision simulation and prevent time drift in long-running games, Unity uses a more complex internal representation for time steps. When you set , the value is quantized to align with the internal high-resolution grid. When this value is cast back to a float for the getter, it can differ by a single bit (one unit of least precision) from the original value due to this internal conversion.
Time.fixedDeltaTimefixedDeltaTimeFor more information on how this property relates to the other time properties, refer to Time and Frame Rate Management in the Unity manual.