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"

StartupModule() not executing?

Hello,

I've simply followed this article: https://wiki.unrealengine.com/Creating_an_Editor_Module Everything compiles fine and all, but for some reason the log is not displaying, so I have a feeling the module startup function might not even be getting called?

MyGameEditor.h

 #pragma once
 
 #include "Engine.h"
 #include "ModuleManager.h"
 #include "UnrealEd.h"
 
 //DECLARE_LOG_CATEGORY_EXTERN(MyGameEditor, Log, All);
 
 class FMyGameEditorModule: public IModuleInterface
 {
 public:
     virtual void StartupModule() override;
     virtual void ShutdownModule() override;
 };

MyGameEditor.cpp

 #include "MyGameEditor.h"
 
 IMPLEMENT_GAME_MODULE(FMyGameEditorModule, MyGameEditor);
 
 //DEFINE_LOG_CATEGORY(MyGameEditor);
 
 #define LOCTEXT_NAMESPACE "MyGameEditor"
 
 void FMyGameEditorModule::StartupModule()
 {
     UE_LOG(LogTemp, Warning, TEXT("This text is  not printing :'C"));
 }
 
 void FMyGameEditorModule::ShutdownModule()
 {
     UE_LOG(LogTemp, Warning, TEXT("Log Ended"));
 }
 
 #undef LOCTEXT_NAMESPACE
 





Product Version: UE 4.10
Tags:
more ▼

asked Feb 10 '16 at 03:37 AM in C++ Programming

avatar image

Penanito
55 10 15 18

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

1 answer: sort voted first

Okay it appears my .uproject file was missing this part:

 {
       "Name": "DarkRelicEditor",
       "Type": "Editor",
       "LoadingPhase":  "PostEngineInit"
 }

under the list of Modules. I remember typing that though...I'm going crazy D:

more ▼

answered Feb 10 '16 at 04:05 AM

avatar image

Penanito
55 10 15 18

(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