EM_Task/UnrealEd/Classes/Factories/BlueprintFactory.h

34 lines
1.2 KiB
C
Raw Normal View History

2026-02-13 16:18:33 +08:00
// Copyright Epic Games, Inc. All Rights Reserved.
/**
*
*/
#pragma once
#include "CoreMinimal.h"
#include "UObject/ObjectMacros.h"
#include "Templates/SubclassOf.h"
#include "Factories/Factory.h"
#include "BlueprintFactory.generated.h"
UCLASS(hidecategories = Object, collapsecategories)
class UNREALED_API UBlueprintFactory: public UFactory
{
GENERATED_UCLASS_BODY()
// The parent class of the created blueprint
UPROPERTY(EditAnywhere, Category = BlueprintFactory, meta = (AllowAbstract = "", BlueprintBaseOnly = ""))
TSubclassOf<class UObject> ParentClass;
// UFactory Interface
virtual bool ConfigureProperties() override;
virtual UObject* FactoryCreateNew(UClass* Class, UObject* InParent, FName Name, EObjectFlags Flags, UObject* Context, FFeedbackContext* Warn, FName CallingContext) override;
virtual UObject* FactoryCreateNew(UClass* Class, UObject* InParent, FName Name, EObjectFlags Flags, UObject* Context, FFeedbackContext* Warn) override;
// End of UFactory Interface
protected:
// Hook for derived classes to indicate if they want to skip some filtering that is unnecessary for macro libraries
virtual bool IsMacroFactory() const { return false; }
};