MCPcopy Create free account
hub / github.com/PCGEx/PCGExtendedToolkit / Boot

Method Boot

Source/PCGExtendedToolkit/Private/Misc/PCGExWriteIndex.cpp:31–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29PCGEX_INITIALIZE_ELEMENT(WriteIndex)
30
31bool FPCGExWriteIndexElement::Boot(FPCGExContext* InContext) const
32{
33 if (!FPCGExPointsProcessorElement::Boot(InContext)) { return false; }
34
35 PCGEX_CONTEXT_AND_SETTINGS(WriteIndex)
36
37 if (Settings->bOutputPointIndex)
38 {
39 PCGEX_VALIDATE_NAME(Settings->OutputAttributeName)
40 Context->bTagsOnly = false;
41 }
42
43 if (Settings->bOutputCollectionIndex && Settings->bOutputCollectionIndexToPoints)
44 {
45 PCGEX_VALIDATE_NAME(Settings->CollectionIndexAttributeName)
46 Context->bTagsOnly = false;
47 }
48
49 if (Settings->bOutputCollectionNumEntries)
50 {
51 if (Settings->bOutputNumEntriesToPoints)
52 {
53 PCGEX_VALIDATE_NAME(Settings->NumEntriesAttributeName)
54 Context->bTagsOnly = false;
55 }
56
57 for (const TSharedPtr<PCGExData::FPointIO>& IO : Context->MainPoints->Pairs)
58 {
59 Context->MaxNumEntries = FMath::Max(Context->MaxNumEntries, IO->GetNum());
60 }
61 }
62
63
64 return true;
65}
66
67bool FPCGExWriteIndexElement::ExecuteInternal(FPCGContext* InContext) const
68{

Callers

nothing calls this directly

Calls 2

MaxFunction · 0.85
GetNumMethod · 0.80

Tested by

no test coverage detected