Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

With 'Screen Space - Camera' render mode, sorting is incorrect #34

Closed
young900101 opened this issue Jan 15, 2019 · 14 comments
Closed

With 'Screen Space - Camera' render mode, sorting is incorrect #34

young900101 opened this issue Jan 15, 2019 · 14 comments
Labels
bug Something isn't working
Milestone

Comments

@young900101
Copy link

ec83fc77-065b-4310-ab8c-2fcfe1ba5a7a

b0e81049-1e34-48f6-89e0-ba0d3fb3f2a4

"xuanwo" is a particle.when i move down "xuanwo",it is above the GreenImage.Why?

@young900101
Copy link
Author

Tested in Unity 2018.3.1f1

@mob-sakai
Copy link
Owner

Hi @young900101
Thank you for reporting.

I would like to know more information on this issue.

  • Is it in play mode or in edit mode, or both?
  • What Canvas.RenderMode did you set?
  • Is ParticleSystem.Renderer disable?
  • Please tell me the version of ParticleEffectForUGUI you are using. [e.g. v1.3.2]
  • Can you submit a reproducible minimum project for this issue?

@young900101
Copy link
Author

1.in play mode.in edit mode,the particle dosen't show.
2.Screen space-camera
3.disabled
4.1.3.2
5.wait a few minutes

@young900101
Copy link
Author

@young900101
Copy link
Author

is this unitypackage available? @mob-sakai

@mob-sakai
Copy link
Owner

Thank you for your reply, @young900101
Your unitypackage is working.

@mob-sakai
Copy link
Owner

Your unitypackage reproduced the issue.

Strangely, it works well with Screen Space - Camera render mode...🤔

@young900101
Copy link
Author

thanks for your reply.particle is above image when i move it? @mob-sakai

Your unitypackage reproduced the issue.

Strangely, it works well with Screen Space - Camera render mode...🤔

that is to say,the situation that the particle is above the image is right? @mob-sakai

@mob-sakai
Copy link
Owner

Oh, I'm sorry, I made a mistake.
Actually, "with Screen Space - Overlay" is correct.

The scene works well with Screen Space - Overlay render mode.

@mob-sakai
Copy link
Owner

I do not know why, but it worked fine when setting transform.localPosition.z to 0.01.
Why...?

@mob-sakai
Copy link
Owner

jan-15-2019 21-28-22

@mob-sakai
Copy link
Owner

Try this script.
UIParticle.cs

@mob-sakai mob-sakai changed the title sort problem In 'Screen Space - Camera' render mode, sorting is incorrect. Jan 15, 2019
@mob-sakai mob-sakai changed the title In 'Screen Space - Camera' render mode, sorting is incorrect. In 'Screen Space - Camera' render mode, sorting is incorrect Jan 15, 2019
@mob-sakai mob-sakai changed the title In 'Screen Space - Camera' render mode, sorting is incorrect With 'Screen Space - Camera' render mode, sorting is incorrect Jan 15, 2019
@young900101
Copy link
Author

Try this script.
UIParticle.cs

Aha~ A strange way!A strange result!
The sorting result is correct as long as z!= 0.But In my view,z is not affect the sorting result of the UGUI.So i feel confused.
Maybe this is not a perfect way to fix this bug,but it works fine.
Moreover,This is an awesome project.Thanks for your time!

@evakimox
Copy link

evakimox commented May 11, 2021

Hello there. Thanks for this great plugin. Sorry for bring this up 2 yrs after.

I am using this UGUIParticle tool with Version 3.3.0. I had no problem in Game view when my canvas is set to Screen Space - Overlay. I am still having sort issue with canvas set to Screen Space - Camera.
I tested on 2 particle systems with Screen Space - Camera canvas.

  1. The first particle system I used the default created particle cone.
  2. The second particle system has no z-axis speed, no z-axis behavior (all particles lies in the same plane)

I tried adjust z axis of the UIParticle. In this case, the 1st particle system always shows everything, while the 2nd particle system display depends on z-axis order.(It sorts element depend on z axis, but does not actually move the object)
sortingProblemWithCameraCanvas

I realized the code has changed a lot since then, so I did not replace the UIParticles.cs file.
I am curious about how the plugin handles different particles.

Also I am using Unity 2019.4.18 with URP 7.5.2. This is the Unitypackage that reproduces my test
UIParticlesSortingProblemDesc.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants