fix: particle trails draw in wrong transform

Close #145
pull/150/head
mob-sakai 2021-02-03 11:16:16 +09:00
parent ba3b80db7a
commit 17ce81eb0e
1 changed files with 1 additions and 1 deletions

View File

@ -241,7 +241,7 @@ namespace Coffee.UIExtensions
var hash = currentPs.GetMaterialHash(true);
if (hash != 0)
{
matrix = currentPs.main.simulationSpace == ParticleSystemSimulationSpace.Local
matrix = currentPs.main.simulationSpace == ParticleSystemSimulationSpace.Local && currentPs.trails.worldSpace
? matrix * Matrix4x4.Translate(-currentPs.transform.position)
: matrix;