Search Unity

Do items need to be active in scene when creating a build in order to generate combined meshes?

Discussion in 'Editor & General Support' started by ArachnidAnimal, Sep 23, 2017.

  1. ArachnidAnimal

    ArachnidAnimal

    Joined:
    Mar 3, 2015
    Posts:
    1,801
    I realized that a gameobject marked as Batching Static must have the mesh renderer enabled and active in hierarchy prior to Unity calling the Start() functions in order for "Combined meshes" to be created in the editor.
    If the mesh renderer is not enabled and active in the hierarchy at this time, no static batching meshes will be created in the Editor automagically.

    Now, do the items need to be active in the scene when performing the build in order for combined meshes to be created for the build?

    The manual makes it seem so straightforward. You just click the "Static" checkbox, and boom, your all set. There are caveats not listed in the manual that prevents static batching from working:
    1. What I listed above
    2. Items using different light probes can't be batched.