Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Maximum allowed timestep in Unity Editor

Discussion in '2D' started by samifruit514, Jun 22, 2018.

  1. samifruit514

    samifruit514

    Joined:
    Mar 27, 2015
    Posts:
    30
    Hello,

    In my game, I need to have a very low fixed timestep (0.02) to avoid physics glitches. When objects collides together, there are damaged and lose life points depending on the collision's normal impulses.

    On mobile everything is smooth and works perfectly. But in the unity editor, the objects seems to be very resistants to collisions compared to what I see in the mobile build. I figured out that if I decrease the maximum allowed timestep, the collisions behaviour is the same as on the mobile, but the game is getting slow.

    I understand what maximum timestep is used for and I understand that it gets slower, but Im very suprised that its getting slow in my unity editor (2017.2.0p2) on my macbook pro while its very smooth on my 2014 ipad.

    This is a problem because we are always testing the game in unity before installing on mobile devices. If we decrease the max allowed timestep, everything will be slow and it will be more painful for us to test (+ we wont have the real UX).

    Anyone knows how I could decrease the max allowed timestep without affecting performances in the editor?
     
  2. samifruit514

    samifruit514

    Joined:
    Mar 27, 2015
    Posts:
    30
    Hello, I figured out that if I select a GO from the hierarchy that has no components, the game almost fast as on mobile. Inspector with lots of components seems to slow down the game and exceed the fixed timestep a lot.