Merge pull request #7576 from aws-lumberyard-dev/aabb-shape-nus
make aabb shape component incompatible with non-uniform scale component
This commit is contained in:
@@ -89,9 +89,10 @@ namespace LmbrCentral
|
||||
provided.push_back(AZ_CRC_CE("AxisAlignedBoxShapeService"));
|
||||
}
|
||||
|
||||
void EditorAxisAlignedBoxShapeComponent::GetDependentServices(AZ::ComponentDescriptor::DependencyArrayType& dependent)
|
||||
void EditorAxisAlignedBoxShapeComponent::GetIncompatibleServices(AZ::ComponentDescriptor::DependencyArrayType& incompatible)
|
||||
{
|
||||
dependent.push_back(AZ_CRC_CE("NonUniformScaleService"));
|
||||
EditorBaseShapeComponent::GetIncompatibleServices(incompatible);
|
||||
incompatible.push_back(AZ_CRC_CE("NonUniformScaleService"));
|
||||
}
|
||||
|
||||
void EditorAxisAlignedBoxShapeComponent::DisplayEntityViewport(
|
||||
@@ -104,7 +105,7 @@ namespace LmbrCentral
|
||||
{
|
||||
DrawBoxShape(
|
||||
{ m_aaboxShape.GetBoxConfiguration().GetDrawColor(), m_shapeWireColor, m_aaboxShape.GetBoxConfiguration().IsFilled() },
|
||||
m_aaboxShape.GetBoxConfiguration(), debugDisplay, m_aaboxShape.GetCurrentNonUniformScale());
|
||||
m_aaboxShape.GetBoxConfiguration(), debugDisplay);
|
||||
},
|
||||
m_aaboxShape.GetCurrentTransform());
|
||||
}
|
||||
@@ -168,6 +169,6 @@ namespace LmbrCentral
|
||||
|
||||
AZ::Vector3 EditorAxisAlignedBoxShapeComponent::GetBoxScale()
|
||||
{
|
||||
return AZ::Vector3(m_aaboxShape.GetCurrentTransform().GetUniformScale() * m_aaboxShape.GetCurrentNonUniformScale());
|
||||
return AZ::Vector3(m_aaboxShape.GetCurrentTransform().GetUniformScale());
|
||||
}
|
||||
} // namespace LmbrCentral
|
||||
|
||||
Reference in New Issue
Block a user