Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice

asdf

Discussion in 'General Discussion' started by xplicitgreek69, Apr 6, 2020.

  1. xplicitgreek69

    xplicitgreek69

    Joined:
    Jan 23, 2020
    Posts:
    34
    asdfsdf​
     
    Last edited: Feb 5, 2023
  2. RLord321

    RLord321

    Joined:
    Feb 25, 2017
    Posts:
    28
    One object will always be better than two because it limits the draw calls. I do make levels made up of pieces like your other option but I take the "level" and combine it in blender and then bring it back to Unity and it treats it as one.
     
    xplicitgreek69 likes this.
  3. neginfinity

    neginfinity

    Joined:
    Jan 27, 2013
    Posts:
    13,337
    In this example It actually shouldn't matter, because number of planes is low, and if they're marked as Static unity will optimize their rendering anyway. Use profiler instead of trying to guess.

    https://docs.unity3d.com/Manual/Profiler.html

    In this scenario I'd use whatever is more convenient for me, and then alter it only if I ran into performance problems.
     
    angrypenguin and xplicitgreek69 like this.
  4. ippdev

    ippdev

    Joined:
    Feb 7, 2010
    Posts:
    3,803
    Second solution should be 25 @ 20x20 planes or 100 @ 10x10 planes. If you densely populate your scene with objects the grid may be a better solution. Really depends on the mechanics you use. Rapidly turning on and off things will burp or choke your frame rate.
     
    xplicitgreek69 likes this.
  5. BIGTIMEMASTER

    BIGTIMEMASTER

    Joined:
    Jun 1, 2017
    Posts:
    5,181
    I say forget the example because it doesn't accurately portray real world scenarios.

    There is a lot of factors at play and it comes down to the details of your specific project. I second @neginfinity advice - design for your workflow and only adjust for performance.

    If the optimization necessitates a big change in workflow that would mean a major do-over, then setup a proper test that is as close to the real thing as possible.

    An example: in my current project, we have big open world. About 100 square kilometers. Conventional wisdom says to using streaming techniques for terrain tiles. So we did this. Turns out, considering all the unique factors of our project, it is actually significantly more performant to not stream the terrains - instead load them all at once. If we had tested the simple way first, would have saved a lot of time and money.
     
    xplicitgreek69 likes this.
  6. seylersteven1

    seylersteven1

    Joined:
    Apr 7, 2020
    Posts:
    3
    I am like one large plan but it depend on plan. ;)
     
    xplicitgreek69 likes this.
  7. Meltdown

    Meltdown

    Joined:
    Oct 13, 2010
    Posts:
    5,796
    Not necessary if you mark your objects as static, Unity will combine them anyway to reduce draw calls.
     
    xplicitgreek69 likes this.
  8. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,066
    Since static batching still does culling for each mesh, it’s not quite the same as it being one giant mesh though.
     
    xplicitgreek69 likes this.