Skip to content

Commit

Permalink
Mark entire HarvestNodeConnections method as editor-only
Browse files Browse the repository at this point in the history
  • Loading branch information
MothDoctor committed Nov 29, 2021
1 parent b283d53 commit 7ad4dd7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
8 changes: 2 additions & 6 deletions Source/Flow/Private/FlowAsset.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ void UFlowAsset::UnregisterNode(const FGuid& NodeGuid)
HarvestNodeConnections();
MarkPackageDirty();
}
#endif

void UFlowAsset::HarvestNodeConnections()
{
Expand Down Expand Up @@ -155,18 +154,15 @@ void UFlowAsset::HarvestNodeConnections()

if (bModified)
{
#if WITH_EDITOR
Node->SetFlags(RF_Transactional);
Node->Modify();
#endif
Node->SetConnections(Connections);

#if WITH_EDITOR
Node->PostEditChange();
#endif
}
}
}
#endif

UFlowNode* UFlowAsset::GetNode(const FGuid& Guid) const
{
Expand Down
2 changes: 1 addition & 1 deletion Source/Flow/Public/FlowAsset.h
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,10 @@ class FLOW_API UFlowAsset : public UObject

void RegisterNode(const FGuid& NewGuid, UFlowNode* NewNode);
void UnregisterNode(const FGuid& NodeGuid);
#endif

// Processes all nodes and creates map of all pin connections
void HarvestNodeConnections();
#endif

UFlowNode* GetNode(const FGuid& Guid) const;
TMap<FGuid, UFlowNode*> GetNodes() const { return Nodes; }
Expand Down

0 comments on commit 7ad4dd7

Please sign in to comment.