From 8f0e418e546fa31d58a729b58bff3cab74d77d17 Mon Sep 17 00:00:00 2001 From: OTHGMars Date: Tue, 11 Jul 2017 19:11:09 -0400 Subject: [PATCH] Fixes collision shape assignment after a PhysicsShapeData resource change signal is triggered. --- Engine/source/T3D/physics/physicsShape.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Engine/source/T3D/physics/physicsShape.cpp b/Engine/source/T3D/physics/physicsShape.cpp index 662fa9769..574707003 100644 --- a/Engine/source/T3D/physics/physicsShape.cpp +++ b/Engine/source/T3D/physics/physicsShape.cpp @@ -257,9 +257,9 @@ void PhysicsShapeData::_onResourceChanged( const Torque::Path &path ) } // Reload the collision shape. - reloadcolShape = shape->buildColShape( false, Point3F::One ); + reloadcolShape = reloadShape->buildColShape( false, Point3F::One ); - if ( bool(reloadShape) && bool(colShape)) + if ( bool(reloadShape) && bool(reloadcolShape)) { shape = reloadShape; colShape = reloadcolShape;