You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
Slight change to the runtime behaviour: when running a layer with the same class as its hosting BP, we use a 'self' layer rather than outputting a warning. #rb Jurre.deBaare [FYI] Jurre.daBaare, Aaron.Cox, Laurent.Delayen #rnx #ROBOMERGE-OWNER: lina.halper #ROBOMERGE-AUTHOR: thomas.sarkanen #ROBOMERGE-SOURCE: CL 6628708 via CL 6629035 via CL 6629054 #ROBOMERGE-BOT: ANIM (Main -> Dev-Anim) (v365-6733468) [CL 6748631 by thomas sarkanen in Dev-Anim branch]
67 lines
2.6 KiB
C++
67 lines
2.6 KiB
C++
// Copyright 1998-2019 Epic Games, Inc. All Rights Reserved.
|
|
|
|
#pragma once
|
|
|
|
#include "CoreMinimal.h"
|
|
#include "UObject/ObjectMacros.h"
|
|
#include "Misc/Guid.h"
|
|
#include "AnimGraphNode_SubInstanceBase.h"
|
|
#include "Animation/AnimNode_Layer.h"
|
|
|
|
#include "AnimGraphNode_Layer.generated.h"
|
|
|
|
class FCompilerResultsLog;
|
|
class IDetailLayoutBuilder;
|
|
class IPropertyHandle;
|
|
class SToolTip;
|
|
|
|
UCLASS(MinimalAPI, Experimental)
|
|
class UAnimGraphNode_Layer : public UAnimGraphNode_SubInstanceBase
|
|
{
|
|
GENERATED_BODY()
|
|
|
|
public:
|
|
|
|
UPROPERTY(EditAnywhere, Category = Settings)
|
|
FAnimNode_Layer Node;
|
|
|
|
//~ Begin UEdGraphNode Interface.
|
|
virtual FText GetTooltipText() const override;
|
|
virtual FText GetNodeTitle(ENodeTitleType::Type TitleType) const override;
|
|
virtual void ValidateAnimNodeDuringCompilation(USkeleton* ForSkeleton, FCompilerResultsLog& MessageLog) override;
|
|
virtual UObject* GetJumpTargetForDoubleClick() const override;
|
|
virtual void JumpToDefinition() const override;
|
|
virtual bool HasExternalDependencies(TArray<class UStruct*>* OptionalOutput /*= NULL*/) const override;
|
|
//~ End UEdGraphNode Interface.
|
|
|
|
// UAnimGraphNode_Base interface
|
|
virtual void CustomizeDetails(IDetailLayoutBuilder& DetailBuilder) override;
|
|
|
|
protected:
|
|
// ----- UI CALLBACKS ----- //
|
|
// Handlers for layer combo
|
|
void GetLayerNames(TArray<TSharedPtr<FString>>& OutStrings, TArray<TSharedPtr<SToolTip>>& OutToolTips, TArray<bool>& OutRestrictedItems);
|
|
FString GetLayerName() const;
|
|
void OnLayerChanged(IDetailLayoutBuilder* DetailBuilder);
|
|
bool HasAvailableLayers() const;
|
|
bool HasValidNonSelfLayer() const;
|
|
// ----- END UI CALLBACKS ----- //
|
|
|
|
// Begin UAnimGraphNode_CustomProperty
|
|
virtual FAnimNode_CustomProperty* GetCustomPropertyNode() override { return &Node; }
|
|
virtual const FAnimNode_CustomProperty* GetCustomPropertyNode() const override { return &Node; }
|
|
void GetExposableProperties( TArray<UProperty*>& OutExposableProperties) const override;
|
|
virtual bool NeedsToSpecifyValidTargetClass() const override { return false; }
|
|
virtual UClass* GetTargetSkeletonClass() const override;
|
|
|
|
// Begin UAnimGraphNode_SubInstanceBase
|
|
virtual FAnimNode_SubInstance* GetSubInstanceNode() override { return &Node; }
|
|
virtual const FAnimNode_SubInstance* GetSubInstanceNode() const override { return &Node; }
|
|
virtual bool OnShouldFilterInstanceBlueprint(const FAssetData& AssetData) const override;
|
|
virtual FString GetCurrentInstanceBlueprintPath() const override;
|
|
virtual bool IsStructuralProperty(UProperty* InProperty) const override;
|
|
|
|
// Helper function to get the interface currently in use by the selected layer
|
|
TSubclassOf<UInterface> GetInterfaceForLayer() const;
|
|
};
|