The problem: I can't fit all my 2d animation sprites for all units and environment in 1 spritesheet.
Everything batches fine until I use two spritesheets... I noticed the following : all units from spritesheet A batch fine until something needs to be rendered fom spritesheet B. so lets say from back to camera : 50units - tree -50 units - camera will result in 3 drawcalls... Not that bad but if you have: unit- tree - unit -tree -unit -tree ... like it's probably most of the time... this wil result in 100+ drawcalls even though you have only two spritesheets...
How can you solve this? Or better, how can i use two spritesheets and have only two drawcalls even though the sprites are at different distances to the camera
Hope this image helps to understand the problem:
1 : the trees are on spritesheet B and batch fine
2: the batching is broken as the unitsprite sits on spritesheet A and is put in between the trees...