sprites and particles overlap

Hi,

I hope someone here can help me.
My Problem is that i have a sprite and particle emitter. both are in the same layer and the Order in the layer is 0 for the sprite and 1 for the emitter. if i have another “pair” of sprite/particle crossing each other my problem is that the particles are over both sprites.

It should be that there is sprite->particle->sprite->particle.

as these pairs are dynamicly created i cant just change the second pairs order to 2/3.
changeing the Z-component didn’t help either.

Whyever not? Right now the sorting order is behaving exactly as you’ve told it to. You’ll need to tell it to do what you want it to do. Whatever script is dynamically creating the emitters needs to set appropriate sorting orders.

the problem is that i have a lot of ships flying around. and some are destroyed and some are rebuild. i know that the problem i have cant be fixed with sorting layers because as you say the are correctly doing what they where told. i need another sollution like putting the hirarchy of the ship in a capsuled something inside the layer so that unity knows this capsule should not be drawn seperatly.

I don’t think that capability exists. But it shouldn’t be hard for you to create. Just set each pair to distinct adjacent sorting orders.