From 17ce81eb0eccb103c21fa553183df97429cf5c6f Mon Sep 17 00:00:00 2001 From: mob-sakai Date: Wed, 3 Feb 2021 11:16:16 +0900 Subject: [PATCH] fix: particle trails draw in wrong transform Close #145 --- Scripts/UIParticleUpdater.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Scripts/UIParticleUpdater.cs b/Scripts/UIParticleUpdater.cs index ef4f6e7..69729e1 100755 --- a/Scripts/UIParticleUpdater.cs +++ b/Scripts/UIParticleUpdater.cs @@ -241,7 +241,7 @@ private static void BakeMesh(UIParticle particle) 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;