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
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Missing objects with static batching after building.

Discussion in 'Editor & General Support' started by Juryiel, Jan 31, 2016.

  1. Juryiel

    Juryiel

    Joined:
    Feb 15, 2014
    Posts:
    21
    My game works fine in the editor and when I hit 'run' in the editor, but when I build it, objects seem to be missing.

    This is related to Static Batching, as it works fine if I'm not doing that. The objects that are missing are random per build (but the same if I re-run the same build) but are all of a specific object type (e.g. I'll have the same object I duplicate with Ctrl+D. Different ones of those will be missing each build). Finally, for some objects I'm able to actually see them if I look from a very specific angle .

    In older versions of unity I read that there are issues with nodraw faces and static batching, which I think I may have in these objects.

    What can I do to fix this? Static batching makes a noticable difference in my game when running it in the editor.
     
  2. Juryiel

    Juryiel

    Joined:
    Feb 15, 2014
    Posts:
    21
    It seems that the problem is related to drawing quads. I moved these quads off of the static batching and all the other objects that were being affected seem to have been fixed. This way I can get the performance (there are not many of these quads).

    Still, why is this happening?