Files
UnrealEngineUWP/Engine/Source/Editor/BlueprintGraph/Classes/K2Node_FunctionTerminator.h
Ben Zeigler 66eb3657e0 #jira UE-74609 Correctly expose Text local variables and function parameters to reference gathering
#jira UE-74857 Change Soft object harvesting for local variables to use a temporarily constructed UFunction instance instead of type-specific hacks
Add FindSignatureFunction and fix function entry tooltip to work for newly created functions
Fix the soft reference fixup code in K2Node to handle references inside a struct, and update CustomEvent/FunctionEntry to update their user pins defaults after a fixup to editor pin data
Right now only local variables are using the value cache as we have too many blueprint pin defaults that cannot be safely copied into properties, will re-evaluate later and fixup comments
#rb michael.noland

[CL 6593293 by Ben Zeigler in Dev-Framework branch]
2019-05-20 21:56:22 -04:00

58 lines
2.2 KiB
C++

// Copyright 1998-2019 Epic Games, Inc. All Rights Reserved.
#pragma once
#include "CoreMinimal.h"
#include "UObject/ObjectMacros.h"
#include "Engine/MemberReference.h"
#include "Templates/SubclassOf.h"
#include "K2Node_EditablePinBase.h"
#include "K2Node_FunctionTerminator.generated.h"
UCLASS(abstract, MinimalAPI)
class UK2Node_FunctionTerminator : public UK2Node_EditablePinBase
{
GENERATED_UCLASS_BODY()
/** Reference to the function signature. This is only resolvable by default if this is an inherited function */
UPROPERTY()
FMemberReference FunctionReference;
//~ Begin UObject Interface
virtual void Serialize(FArchive& Ar) override;
//~ End UObject Interface
//~ Begin UEdGraphNode Interface
virtual bool CanDuplicateNode() const override { return false; }
virtual FLinearColor GetNodeTitleColor() const override;
virtual FName CreateUniquePinName(FName SourcePinName) const override;
virtual void ValidateNodeDuringCompilation(class FCompilerResultsLog& MessageLog) const override;
//~ End UEdGraphNode Interface
//~ Begin UK2Node Interface
virtual bool NodeCausesStructuralBlueprintChange() const override { return true; }
virtual bool HasExternalDependencies(TArray<class UStruct*>* OptionalOutput) const override;
//~ End UK2Node Interface
//~ Begin UK2Node_EditablePinBase Interface
virtual bool CanCreateUserDefinedPin(const FEdGraphPinType& InPinType, EEdGraphPinDirection InDesiredDirection, FText& OutErrorMessage) override;
//~ End UK2Node_EditablePinBase Interface
/** Promotes the node from being a part of an interface override to a full function that allows for parameter and result pin additions */
BLUEPRINTGRAPH_API virtual void PromoteFromInterfaceOverride(bool bIsPrimaryTerminator = true);
/** Returns the UFunction that this node actually represents, this will work for both inherited and newly created functions */
BLUEPRINTGRAPH_API UFunction* FindSignatureFunction() const;
private:
/** (DEPRECATED) Function signature class. Replaced by the 'FunctionReference' property. */
UPROPERTY()
TSubclassOf<class UObject> SignatureClass_DEPRECATED;
/** (DEPRECATED) Function signature name. Replaced by the 'FunctionReference' property. */
UPROPERTY()
FName SignatureName_DEPRECATED;
};