From 8668fac564d38fec00b142bc309ab405106257d7 Mon Sep 17 00:00:00 2001 From: Mikhail Naumov <82239319+AMZN-mnaumov@users.noreply.github.com> Date: Thu, 6 Jan 2022 19:09:27 -0600 Subject: [PATCH] Fixing character controller triggering collision on creation (#6546) * Fixing character controller triggering collision on creation Signed-off-by: Mikhail Naumov * PR feedback Signed-off-by: Mikhail Naumov --- Gems/PhysX/Code/Source/PhysXCharacters/API/CharacterUtils.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/Gems/PhysX/Code/Source/PhysXCharacters/API/CharacterUtils.cpp b/Gems/PhysX/Code/Source/PhysXCharacters/API/CharacterUtils.cpp index f4cdd01889..1151c0ffff 100644 --- a/Gems/PhysX/Code/Source/PhysXCharacters/API/CharacterUtils.cpp +++ b/Gems/PhysX/Code/Source/PhysXCharacters/API/CharacterUtils.cpp @@ -73,6 +73,7 @@ namespace PhysX::Utils::Characters physx::PxMaterial* pxMaterial = static_cast(materials.front()->GetNativePointer()); controllerDesc.material = pxMaterial; + controllerDesc.position = PxMathConvertExtended(characterConfig.m_position); controllerDesc.slopeLimit = cosf(AZ::DegToRad(characterConfig.m_maximumSlopeAngle)); controllerDesc.stepOffset = characterConfig.m_stepHeight; controllerDesc.upDirection = characterConfig.m_upDirection.IsZero()