From aef87738832a871ed1f8445987537245a997810f Mon Sep 17 00:00:00 2001 From: tristan Date: Fri, 29 Jun 2018 11:45:47 +0200 Subject: [PATCH] UPBGE: Fix KX_GameObject::NodeSetGlobalOrientation. --- source/gameengine/Ketsji/KX_GameObject.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/gameengine/Ketsji/KX_GameObject.cpp b/source/gameengine/Ketsji/KX_GameObject.cpp index 339cd87f827a..53af2fef23e7 100644 --- a/source/gameengine/Ketsji/KX_GameObject.cpp +++ b/source/gameengine/Ketsji/KX_GameObject.cpp @@ -1240,7 +1240,7 @@ void KX_GameObject::NodeSetGlobalOrientation(const mt::mat3& rot) { SG_Node *parentSgNode = m_sgNode->GetParent(); if (parentSgNode) { - NodeSetLocalOrientation(parentSgNode->GetParent()->GetWorldOrientation().Inverse() * rot); + NodeSetLocalOrientation(parentSgNode->GetWorldOrientation().Inverse() * rot); } else { NodeSetLocalOrientation(rot);