- Home /
Particle system draw order with two particle systems
I have two particle systems (A and B) and I need to have them drawn sorted by distance. I have sort by distance enabled under the particle system's renderer tab. However, Unity will always draw particle system A before B or B before A. But I need the particles to be sorted.
This gif is not mine but it illustrates the problem well: You may need to click the link to see it play: https://media.giphy.com/media/l41lNtmqe2huxPDe8/giphy.gif
Either the black smoke is in front of all the dust or the black smoke is behind all the dust. But both are incorrect, the black smoke should be in middle of the dust, sorted by distance.
I would appreciate any help.
What is the sorting fudge value of both particle systems?
@ifurkend Sorting fudge value is zero. By changing it I can change whether particles from system A show in front of B or the other way around. But I need the particles to be drawn in depth order, neither system appearing in front of the other.
Answer by ifurkend · Jun 22, 2017 at 03:04 PM
It seems both A and B PSs share the same emitter position. Unfortunately Unity cannot handle precise transparency sorting of such close distance. I guess you want the whole smoke effect appears bright on one side and dark another side, this should only be done via shader instead of overlapping 2 PSs. Asset store has many smoke shaders providing volumetric effect, I have one similar shared on the forum which simply rotates the gradient map according to the rotation of primary directional light.
Your answer
Follow this Question
Related Questions
PS Custom Vertex Streams to Particle Trail 0 Answers
Shuriken particle System - change velocity by trigger 0 Answers
How to make particles react to movement of particle system 4 Answers
Need help with Particle System 0 Answers
How to edit the new particle surface shader? / Make it so particles receive light from all angles 0 Answers