Was having a problem accessing GameInstance in the Editor to access some properties I made initialized in GameInstance, now I realize GI does not persist between PIE sessions.
So after a bit of googleing, I decided to try to make an Engine and Editor Subsystem, only now I cannot package my app.
Do I have to register my subsystems somewhere in their constructors, or is this done automatically? I put log code in the constructor and initializer, and it runs
Do I have to add something to my build.cs file? I tried all the obvious things, but none of them allowed me to package my app - but I can build for PIE with no errors if I remove the extras I tried in build.cs
The output log gives me error
Missing precompiled manifest for âEditorSubsystemâ, âD:\EpicGames\UE_5.3\Engine\Intermediate\Build\Win64\UnrealGame\Development\EditorSubsystem\EditorSubsystem.precompiledâ. This module was most likely not flagged for being included in a precompiled build - set âPrecompileForTargets = PrecompileTargetsType.Any;â in EditorSubsystem.build.cs to override. If part of a plugin, also check if its âTypeâ is correct.
I have looked into this, and can see the precompile file is missing, but I absolutely do not understand how to get this file! The EditorSubsystem.build.cs file I can find on my system, but it doesnt contain âPrecompileForTargetsâ for targets for me to set. Should I just add this line?
Deciding this was all hell, I deleted my new Editor/Engine subsystems , deleted a bunch of folders and rebuilt the .sln file, which all worked well, but when trying to package, I still got the error above preventing the build even though the subsystems are physically deleted from the project. Previous versions of the app packaged ok before I added/deleted the subclasses. How do I get rid of this error?
So, I spent a sleepless night looking for a fix for this. In my project I use both Engine Subsystem and Editor Subsystem. There are no problems when packaging a project only with Engine Subsystem. The problem with Editor Subsystem is connecting editor modules.Anything related to the editor should not be included in the build, at least if you are using UE from the Marketplace.
A temporary and quick solution to packaging problems is to disable the âEditorSubsystemâ module in .uproject. Just remove it and rebuild the solution and project.
To use Editor Subsystem without crutches. Create an editor plugin and implement Editor Subsystem in it. You donât need to register your Subsystem, Unreal does it for you. The only thing I did was override the Initialize() and Deinitialize() functions.
The licensing agreement we have with EPIC doesnât allow editor stuff to be packaged at all. Whether you are building the engine yourself or not.
You can only distribute editor stuff through the epic marketplace.
You can make tools & stuff, using editor code & assets. That is after all the purpose of the UE Marketplace
But, say you wanted to make a 3D editor inside your game for instance. Or just let people use a transform gizmo to place items inside their game-home. Well you couldnât re-use the editor for that purpose I believe.
d. Restrictions on Engine Tools
If your Product includes Engine Tools, you may only Distribute it through either the Fab Marketplace, the Unreal Engine Marketplace or through a fork of Epicâs GitHub UnrealEngine Network. âEngine Toolsâ means the (i) editors and other tools included in the Engine Code; (ii) any code and modules in either the Developer or Editor folders, including in object code format, whether statically or dynamically linked; and (iii) other software that may be used to develop standalone products based on the Licensed Technology.
I know you meant from a technical point of view, but since itâs outside the license agreement, it felt like a good argument to encourage you to discontinue this direction
The way I do it myself is, in build.cs, I use: if (Target.bBuildEditor == true) before adding my custom editor dependencies.
And in my .uplugin I use the module type âEditorâ. I do not actually use âEditorSubsystemâ as an AdditionalDependency in the .uproject.
But to be extra clear: Yes, there was a lot of trial and error involved as well! Itâs far from intuitive.
Thanks, that was a good and helpful explanation of the license agreement. I did not know about it)
âEditorSubsystemâ automatically appears in .uproject if you create the âEditorSubsystemâ class in the main project. Therefore, even after deleting the class, a build error appears. And unfortunately this is difficult to notice without version control)