How to Extend UnrealEdEngine?

Dear Friends at Epic,

I see in baseengine.ini I can choose a base class for UnrealEdEngine

[/Script/Engine.Engine]
EditorEngine=/Script/UnrealEd.EditorEngine
UnrealEdEngine=/Script/UnrealEd.UnrealEdEngine

Presumably I could extend it and write in my own editor functionality as a plugin for others to use.

I am having trouble extending UnrealEdEngine :slight_smile:

1>e:\rocketvictory\victorygame\intermediate\builddata\include\victorygame\../../../../Source/VictoryGame/Classes/VictoryEdEngine.h(9): error C2504: 'UUnrealEdEngine' : base class undefined
1>e:\rocketvictory\victorygame\intermediate\builddata\include\victorygame\../../../../Source/VictoryGame/Classes/VictoryEdEngine.h(10): error C2146: syntax error : missing ';' before identifier 'Super'
1>e:\rocketvictory\victorygame\intermediate\builddata\include\victorygame\../../../../Source/VictoryGame/Classes/VictoryEdEngine.h(10): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>e:\rocketvictory\victorygame\intermediate\builddata\include\victorygame\../../../../Source/VictoryGame/Classes/VictoryEdEngine.h(9): error C2504: 'UUnrealEdEngine' : base class undefined

I tried adding

SharedPCHHeaderFile = "Runtime/Engine/Public/Engine.h";

to my build target but that did not change anything

Here’s my class:

#pragma once

#include "Engine.h"

#include "VictoryEdEngine.generated.h"

UCLASS(config=Engine, transient)
class UVictoryEdEngine : public UUnrealEdEngine
{
	GENERATED_UCLASS_BODY()


};

// Copyright 1998-2013 Epic Games, Inc. All Rights Reserved.

#include "VictoryGame.h"

UVictoryEdEngine::UVictoryEdEngine(const class FPostConstructInitializeProperties& PCIP)
	: Super(PCIP)
{
}

Hi Rama,

Thank you for your feedback. It looks like you may need to include some more headers. Try adding:

#include UnrealEd.h 

Please let me know if that does not resolve the issue and I will be happy to further assist.

Cheers!

Alexander

Woohoo that did Alexander, Thanks!

Unfortunately now my compile times went from 5 seconds to 70 seconds, but hey, this pic says it all

For future answer seekers, “UnrealEd.h” is quite a monolithic header that includes a lot of other headers. To only “include what you use” include “Editor/UnrealEdEngine.h” instead.