x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Extending Editor by Modules

Hi there,

My problem is a little weird and is probably the result of a little misunderstanding about the build system, so I'm sorry! Before I try to explain the situation, I have to say that I'm using the 4.4.3 build at the moment.

I tried to extend the features of my Editor by adding a new module, named BrEditor. This link on the answerhub and this one on the documentation helped me. (By the way, I wanted to ask : is the documentation up to date?).

Following these links, I have now these files in my architecture :

BassRider.Target.cs:

 using UnrealBuildTool;
 using System.Collections.Generic;
 
 public class BassRidersTarget : TargetRules
 {
     public BassRidersTarget(TargetInfo Target)
     {
         Type = TargetType.Game;
     }
 
     //
     // TargetRules interface.
     //
 
     public override void SetupBinaries(
         TargetInfo Target,
         ref List<UEBuildBinaryConfiguration> OutBuildBinaryConfigurations,
         ref List<string> OutExtraModuleNames
         )
     {
         OutExtraModuleNames.Add("BassRiders");
 
         if (UEBuildConfiguration.bBuildEditor)
         {
             OutExtraModuleNames.Add("BrEditor");
         }
     }
 }

BassRidersEditor.Target.cs :

 using UnrealBuildTool;
 using System.Collections.Generic;
 
 public class BassRidersEditorTarget : TargetRules
 {
     public BassRidersEditorTarget(TargetInfo Target)
     {
         Type = TargetType.Editor;
     }
 
     //
     // TargetRules interface.
     //
 
     public override void SetupBinaries(
         TargetInfo Target,
         ref List<UEBuildBinaryConfiguration> OutBuildBinaryConfigurations,
         ref List<string> OutExtraModuleNames
         )
     {
         OutExtraModuleNames.Add("BassRiders");
         OutExtraModuleNames.Add("BrEditor");
     }
 }

BrEditor.Target.cs :

 using UnrealBuildTool;
 
 public class BrEditor : ModuleRules
 {
     public BrEditor(TargetInfo Target)
     {
         PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore", "UnrealEd", "BassRiders" });
     }
 }

BrEditor.h :

 #ifndef __BREDITOR_H__
 #define __BREDITOR_H__
 
 #include "EngineMinimal.h"
 
 #endif

BrEditor.cpp :

 #include "BrEditor.h"
 
 
 IMPLEMENT_GAME_MODULE(FDefaultGameModuleImpl, BrEditor);
  

If you want an overview of the files :

alt text

The problem is that this module was working fine for a whole month. But when my co-worker tried to pull my branch, he wasn't able to compile the module. The funny part is... I'm now in the same situation and can't build the project now (because I tried to reproduce this problem). I think that the problem lies in the Config/DefaultEngine.ini files. Mainly because I added things, and deleted it later. So my idea is that, because of some caching feature, I was able to automagically build the module despite the fact that my configuration wasn't accurate.

Could you please provide me some informations to add modules to the UnrealEditor the proper way? If you have some links about the *Engine.ini files too, I'll be glad to read them.

Thanks in advance for your help!

Product Version: Not Selected
Tags:
overview.png (10.3 kB)
more ▼

asked Oct 18 '14 at 11:06 AM in Packaging & Deployment

avatar image

ByOu
88 3 17 11

avatar image Llew Oct 20 '14 at 02:26 PM

Hello there,

Here is the beginning of the far too long error output:

 1>c:\program files\epic games\4.4\engine\source\runtime\coreuobject\public\uobject\Script.h(298): error C2061
 1>c:\program files\epic games\4.4\engine\source\runtime\coreuobject\public\uobject\Script.h(298): error C4430
 1>c:\program files\epic games\4.4\engine\source\runtime\coreuobject\public\uobject\Script.h(298): error C4183

Our problem is very similar to this one: https://answers.unrealengine.com/questions/41509/extending-editor-engine.html but sadly we weren't able to fix it yet.

Thank you for your help

avatar image ByOu Oct 21 '14 at 10:38 AM

Hi again!

We managed to compile our module thanks to a weird trick.

1 : We deleted our client code, just keeping the module files (BrEditor.h, BrEditor.cpp);

2 : We deleted binaries/intermediate folders and regenerate the project files;

3 : We compiled successfully the solution with this useless module;

4 : We added the client code (MapBuilder.*), regenerate project files, and compiled the project successfully.

The thing is : we have to use this trick if we need to regenerate project files for any reason. I think that we made a mistake somewhere because my feeling is that the project is compiling thanks to incremental compilation (maybe the UObjects symbols are included in the "empty module compilation" and so, the second compilation works).

If anyone knows how to fix this, I thank you in advance Sir!

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

Fixed

I was the prefixe of the file, fixed by renaming MyFile to [XX]MyFile.

more ▼

answered Oct 23 '14 at 11:09 PM

avatar image

Llew
21 1 3

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

Hi again,

Here is the code inside our module that seems to cause the issue:

 UCLASS()
 class BREDITOR_API AMapBuilder : public APawn
 {
     GENERATED_UCLASS_BODY()
 

...

 };

Is there something specific in the declaration missing ?

more ▼

answered Oct 23 '14 at 12:45 PM

avatar image

Llew
21 1 3

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question