Minor performance optimization to Prefab Instance.
Signed-off-by: AMZN-koppersr <82230785+AMZN-koppersr@users.noreply.github.com>
This commit is contained in:
@@ -142,14 +142,14 @@ namespace AzToolsFramework
|
||||
return m_templateSourcePath;
|
||||
}
|
||||
|
||||
void Instance::SetTemplateSourcePath(AZ::IO::PathView sourcePath)
|
||||
void Instance::SetTemplateSourcePath(AZ::IO::Path sourcePath)
|
||||
{
|
||||
m_templateSourcePath = sourcePath;
|
||||
m_templateSourcePath = AZStd::move(sourcePath);
|
||||
}
|
||||
|
||||
void Instance::SetContainerEntityName(AZStd::string_view containerName)
|
||||
void Instance::SetContainerEntityName(AZStd::string containerName)
|
||||
{
|
||||
m_containerEntity->SetName(containerName);
|
||||
m_containerEntity->SetName(AZStd::move(containerName));
|
||||
}
|
||||
|
||||
bool Instance::AddEntity(AZ::Entity& entity)
|
||||
|
||||
@@ -80,8 +80,8 @@ namespace AzToolsFramework
|
||||
void SetTemplateId(TemplateId templateId);
|
||||
|
||||
const AZ::IO::Path& GetTemplateSourcePath() const;
|
||||
void SetTemplateSourcePath(AZ::IO::PathView sourcePath);
|
||||
void SetContainerEntityName(AZStd::string_view containerName);
|
||||
void SetTemplateSourcePath(AZ::IO::Path sourcePath);
|
||||
void SetContainerEntityName(AZStd::string containerName);
|
||||
|
||||
bool AddEntity(AZ::Entity& entity);
|
||||
bool AddEntity(AZStd::unique_ptr<AZ::Entity>&& entity);
|
||||
|
||||
+1
@@ -154,6 +154,7 @@ namespace AzToolsFramework::Prefab::PrefabConversionUtils
|
||||
{
|
||||
using namespace AzToolsFramework::Prefab;
|
||||
|
||||
// Resolve prefab links into spawnable links for the provided spawnable.
|
||||
for (EntityAliasStore& entityAlias : m_entityAliases)
|
||||
{
|
||||
auto sourcePrefab = AZStd::get_if<EntityAliasPrefabLink>(&entityAlias.m_source);
|
||||
|
||||
Reference in New Issue
Block a user