diff options
Diffstat (limited to 'scene/2d/cpu_particles_2d.cpp')
-rw-r--r-- | scene/2d/cpu_particles_2d.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/scene/2d/cpu_particles_2d.cpp b/scene/2d/cpu_particles_2d.cpp index 3649746c40..3f6035d309 100644 --- a/scene/2d/cpu_particles_2d.cpp +++ b/scene/2d/cpu_particles_2d.cpp @@ -743,7 +743,7 @@ void CPUParticles2D::_particles_process(float p_delta) { Vector2 normal = emission_normals.get(random_idx); Transform2D m2; m2.set_axis(0, normal); - m2.set_axis(1, normal.tangent()); + m2.set_axis(1, normal.orthogonal()); p.velocity = m2.basis_xform(p.velocity); } @@ -908,7 +908,7 @@ void CPUParticles2D::_particles_process(float p_delta) { if (particle_flags[PARTICLE_FLAG_ALIGN_Y_TO_VELOCITY]) { if (p.velocity.length() > 0.0) { p.transform.elements[1] = p.velocity.normalized(); - p.transform.elements[0] = p.transform.elements[1].tangent(); + p.transform.elements[0] = p.transform.elements[1].orthogonal(); } } else { |