更新 Source/FLESH/Private/DismembermentGraph/DismembermentGraphBase.cpp
This commit is contained in:
@@ -19,8 +19,9 @@ void UDismembermentGraphBase::ClearGraph()
|
||||
|
||||
UEdGraphNode* UDismembermentGraphBase::AddNode(TSubclassOf<UEdGraphNode> NodeClass, const FVector2D& Position)
|
||||
{
|
||||
// Create new node
|
||||
UEdGraphNode* NewNode = NewObject<UEdGraphNode>(this, NodeClass);
|
||||
// Create new node with a unique name
|
||||
FString NodeName = FString::Printf(TEXT("Node_%s_%d"), *NodeClass->GetName(), Nodes.Num());
|
||||
UEdGraphNode* NewNode = NewObject<UEdGraphNode>(this, NodeClass, *NodeName, RF_Transactional);
|
||||
if (NewNode)
|
||||
{
|
||||
// Set node position
|
||||
|
Reference in New Issue
Block a user