From 1e5ea3e5c43f8cb4d890a7e1e2c1283f33b6a057 Mon Sep 17 00:00:00 2001 From: Mitchell Stokes Date: Sat, 12 Jan 2013 23:48:40 +0000 Subject: [PATCH] BGE: Fix from HG1 for bug [#32831] "TrackTo aktuator +X direction not working correct" reported by HG1. Looks like a vector needed to be inverted for the +X calculation. --- source/gameengine/Ketsji/KX_TrackToActuator.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/gameengine/Ketsji/KX_TrackToActuator.cpp b/source/gameengine/Ketsji/KX_TrackToActuator.cpp index 1597948bafe..be2b40316e8 100644 --- a/source/gameengine/Ketsji/KX_TrackToActuator.cpp +++ b/source/gameengine/Ketsji/KX_TrackToActuator.cpp @@ -294,7 +294,7 @@ bool KX_TrackToActuator::Update(double curtime, bool frame) { // (1.0 , 0.0 , 0.0 ) x direction is forward, z (0.0 , 0.0 , 1.0 ) up left = dir.safe_normalized(); - dir = (left.cross(up)).safe_normalized(); + dir = -(left.cross(up)).safe_normalized(); mat.setValue ( left[0], dir[0],up[0], left[1], dir[1],up[1],