From 2b0ba9ba85ef9b5bca1cff27b54770b89a2854dd Mon Sep 17 00:00:00 2001 From: ueshita Date: Mon, 26 Feb 2024 09:50:30 +0900 Subject: [PATCH] Fix directional billboard behavior by spawn rotation --- Dev/Cpp/Effekseer/Effekseer/Effekseer.Instance.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Dev/Cpp/Effekseer/Effekseer/Effekseer.Instance.cpp b/Dev/Cpp/Effekseer/Effekseer/Effekseer.Instance.cpp index ee0ad0f938..983f8d7c03 100644 --- a/Dev/Cpp/Effekseer/Effekseer/Effekseer.Instance.cpp +++ b/Dev/Cpp/Effekseer/Effekseer/Effekseer.Instance.cpp @@ -372,6 +372,8 @@ void Instance::FirstUpdate() if (m_pEffectNode->GenerationLocation.EffectsRotation) { prevPosition_ = SIMD::Vec3f::Transform(prevPosition_, m_GenerationLocation); + globalDirection_ = SIMD::Vec3f::Transform(globalDirection_, m_GenerationLocation.Get3x3SubMatrix()); + globalDirection_ = SIMD::Vec3f::Transform(globalDirection_, m_ParentMatrix); } else {