Exposed a new property bIsEditable on UDynamicMeshComponent to allow them to block any modifications done through EditMesh/SetMesh. Additionally, when this flag is set to false, the UDynamicMeshToolTarget is blocked from being created for the dynamic mesh component so modeling tools can't edit the mesh either.

#rb Ryan.Schmidt

[CL 29959323 by roey borsteinas in ue5-main branch]
This commit is contained in:
roey borsteinas
2023-11-28 09:50:36 -05:00
parent 62e4c45d92
commit e168d21835
3 changed files with 34 additions and 13 deletions
@@ -230,6 +230,7 @@ bool UDynamicMeshComponentToolTargetFactory::CanBuildTarget(UObject* SourceObjec
&& !Component->IsUnreachable()
&& Component->IsValidLowLevel()
&& Component->GetDynamicMesh()
&& Component->IsEditable()
&& Requirements.AreSatisfiedBy(UDynamicMeshComponentToolTarget::StaticClass());
}