Added configurable physics materials per asset in PhysX group in FBX Settings. (#1186)
- Added back the' Physics Materials from Asset' tick in the collider components. - Made physics materials names case insensitive. - Refactored how to gather material information from fbx and used the same code for exporter and physx groups.
This commit is contained in:
@@ -15,12 +15,12 @@
|
||||
|
||||
#include <AzFramework/Physics/PropertyTypes.h>
|
||||
|
||||
#include <QString>
|
||||
|
||||
namespace PhysX
|
||||
{
|
||||
namespace Editor
|
||||
{
|
||||
static const char* const DefaultPhysicsMaterialLabel = "<Default Physics Material>";
|
||||
|
||||
AZ::u32 MaterialIdWidget::GetHandlerName() const
|
||||
{
|
||||
return Physics::Edit::MaterialIdSelector;
|
||||
@@ -74,7 +74,7 @@ namespace PhysX
|
||||
|
||||
auto lockToDefault = [gui]()
|
||||
{
|
||||
gui->addItem(DefaultPhysicsMaterialLabel);
|
||||
gui->addItem(QLatin1String(Physics::DefaultPhysicsMaterialLabel.data(), Physics::DefaultPhysicsMaterialLabel.size()));
|
||||
gui->setCurrentIndex(0);
|
||||
return false;
|
||||
};
|
||||
@@ -103,7 +103,7 @@ namespace PhysX
|
||||
|
||||
// Add default physics material first
|
||||
m_libraryIds.push_back(Physics::MaterialId());
|
||||
gui->addItem(DefaultPhysicsMaterialLabel);
|
||||
gui->addItem(QLatin1String(Physics::DefaultPhysicsMaterialLabel.data(), Physics::DefaultPhysicsMaterialLabel.size()));
|
||||
|
||||
for (const auto& material : materials)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user