Corrects transform order for collider

Reorders the transform application to translation, scale, then rotation.

This ensures the collider’s world matrix is constructed correctly, preventing potential scaling or rotation issues in the GJK algorithm being developed on this branch.
This commit is contained in:
2025-11-09 17:15:01 +03:00
parent 79482d56d1
commit ca3dab855b

View File

@@ -28,7 +28,7 @@ namespace omath::collision
[[nodiscard]]
source_engine::Mat4X4 to_world() const
{
return mat_scale(m_scale) * mat_translation(m_origin) * source_engine::rotation_matrix(m_rotation);
return mat_translation(m_origin) * mat_scale(m_scale) * source_engine::rotation_matrix(m_rotation);
}
[[nodiscard]]