The following recipes all interact with editor mode-specific code and engine modules. As a result, it is considered good practice to create a new module that will only be loaded when the engine is running in editor mode so that we can place all our editor-only code inside it.
Open your project's
.uproject
file in a text editor such as Notepad or Notepad++.Add the bolded section of the following to the file:
{ "FileVersion": 3, "EngineAssociation": "4.11", "Category": "", "Description": "", "Modules": [ { "Name": "UE4Cookbook", "Type": "Runtime", "LoadingPhase": "Default", "AdditionalDependencies": [ "Engine", "CoreUObject" ] }, { "Name": "UE4CookbookEditor", "Type": "Editor", "LoadingPhase": "PostEngineInit", "AdditionalDependencies": [ "Engine", "CoreUObject" ] } ] }
Note the comma after the first module before the second set of curly...