| 990 | } |
| 991 | |
| 992 | void UFlowAsset::FinishFlow(const EFlowFinishPolicy InFinishPolicy, const bool bRemoveInstance /*= true*/) |
| 993 | { |
| 994 | FinishPolicy = InFinishPolicy; |
| 995 | |
| 996 | CancelAndWarnForUnflushedDeferredTriggers(); |
| 997 | |
| 998 | // end execution of this asset and all of its nodes |
| 999 | for (UFlowNode* Node : ActiveNodes) |
| 1000 | { |
| 1001 | Node->Deactivate(); |
| 1002 | } |
| 1003 | ActiveNodes.Empty(); |
| 1004 | |
| 1005 | // flush preloaded content |
| 1006 | for (UFlowNode* PreloadedNode : PreloadedNodes) |
| 1007 | { |
| 1008 | PreloadedNode->TriggerFlush(); |
| 1009 | } |
| 1010 | PreloadedNodes.Empty(); |
| 1011 | |
| 1012 | // provides option to finish game-specific logic prior to removing asset instance |
| 1013 | if (bRemoveInstance) |
| 1014 | { |
| 1015 | DeinitializeInstance(); |
| 1016 | } |
| 1017 | } |
| 1018 | |
| 1019 | void UFlowAsset::CancelAndWarnForUnflushedDeferredTriggers() |
| 1020 | { |
no test coverage detected