You've already forked ParticleEffectForUGUI
mirror of
https://github.com/mob-sakai/ParticleEffectForUGUI.git
synced 2026-05-20 07:20:12 +00:00
fix #15; Canvas.scaleFactor not take into account
This commit is contained in:
@@ -222,7 +222,7 @@ namespace Coffee.UIExtensions
|
|||||||
CheckTrail ();
|
CheckTrail ();
|
||||||
Profiler.EndSample ();
|
Profiler.EndSample ();
|
||||||
|
|
||||||
if (m_ParticleSystem)
|
if (m_ParticleSystem && canvas)
|
||||||
{
|
{
|
||||||
Profiler.BeginSample ("Disable ParticleSystemRenderer");
|
Profiler.BeginSample ("Disable ParticleSystemRenderer");
|
||||||
if (Application.isPlaying)
|
if (Application.isPlaying)
|
||||||
@@ -232,7 +232,7 @@ namespace Coffee.UIExtensions
|
|||||||
Profiler.EndSample ();
|
Profiler.EndSample ();
|
||||||
|
|
||||||
Profiler.BeginSample ("Make Matrix");
|
Profiler.BeginSample ("Make Matrix");
|
||||||
var s = scale;
|
var s = scale * canvas.scaleFactor;
|
||||||
scaleaMatrix = Matrix4x4.Scale (new Vector3 (s, s, s));
|
scaleaMatrix = Matrix4x4.Scale (new Vector3 (s, s, s));
|
||||||
Matrix4x4 matrix = default (Matrix4x4);
|
Matrix4x4 matrix = default (Matrix4x4);
|
||||||
switch (m_ParticleSystem.main.simulationSpace)
|
switch (m_ParticleSystem.main.simulationSpace)
|
||||||
|
|||||||
Reference in New Issue
Block a user