Search Unity

DOTS makes the game slower. Why?

Discussion in 'Entity Component System' started by Xtro, Apr 29, 2020.

  1. Xtro

    Xtro

    Joined:
    Apr 17, 2013
    Posts:
    610
    Hello.

    I'm just starting to work with DOTS. Without writing any code, I just wanted to convert the simple objects to DOTS to be able to see the performance benefits of it but the result I experienced is very surprising in a bad way.

    I'm using Hybrid Renderer 0.4.2 and Entities 0.9.1.

    To test this, I imported a 3rd party forest scene from asset store. It runs around 260 fps in Unity editor on my computer.
    Then I added ConvertToEntity component to all simple objects in the scene such as trees, walls and barrels. Fps dropped to 188!

    Hey! what's going on here?
     
  2. InAngel

    InAngel

    Joined:
    Dec 30, 2017
    Posts:
    33
    Got the same effect recently,
    the Hybrid Renderer v1 is very slow and that is what causing the fps drop.
    the new version should be out in 2020 and it would fix that issue.
     
  3. eizenhorn

    eizenhorn

    Joined:
    Oct 17, 2016
    Posts:
    2,685
    Which pipeline you using? For DOTS preferred SRP with Hybrid Renderer v2, v1 much slower than that.
     
  4. thelebaron

    thelebaron

    Joined:
    Jun 2, 2013
    Posts:
    857
    Things to try -
    Disable safety checks
    Enable material instancing
    Use static optimize
    Profile in build
     
  5. PublicEnumE

    PublicEnumE

    Joined:
    Feb 3, 2019
    Posts:
    729
    Is it currently possible to use HR v2, using only packages installed through the Package Manager?

    it’s been a bit difficult to track down info on this.
     
  6. thelebaron

    thelebaron

    Joined:
    Jun 2, 2013
    Posts:
    857
    Yes with 9.x of either srp(though there may be issues given what Ive read here and on discord).
     
  7. DreamersINC

    DreamersINC

    Joined:
    Mar 4, 2015
    Posts:
    131
    Check you Leak Detection setting in Jobs tab.