Download

no LOG msg in spite of the usefull tutorial of RAMA

Hello,
I posted several topics this last days and thank for your helps.
Be sure that it is always disappointing to not be able to find the solution by myself !! UE4 is not as easy to use as I expected.
But I think that the final result will worth it …

So my new issue (and probably not the last) is about LOG messages. Obviously log works and I can see many messages into the “output log” of the editor.
And because the UE_LOG macro is inside the StartupModule function, I’m pretty sure that it should be printed.

This is the code of my basic game module :

MySRV2.cpp


DEFINE_LOG_CATEGORY(MyLog);

IMPLEMENT_PRIMARY_GAME_MODULE( FDefaultGameModuleImpl, MySRV2, "MySRV2");

void MySRV2::StartupModule() {
	UE_LOG(LogTemp, Warning, TEXT("Your message"));
	UE_LOG(MyLog, Warning, TEXT("TEST !!!"));
	}
void MySRV2::ShutdownModule() {
	UE_LOG(LogTemp, Warning, TEXT("ShutdownModule !!!"));
}

and MySRV2.h


DECLARE_LOG_CATEGORY_EXTERN(MyLog, Log, All);

class MySRV2 : public FDefaultGameModuleImpl {
	virtual void StartupModule() override;
	virtual void ShutdownModule() override;
};

Any idea ?

I begin to have a doubt.
From time to time, very rarely, I get the log messages that you can see into the StartupModule.

That probably mean that the function “StartupModule” is not launched each time I press “PLAY” …

OK, everythings works fine if I put it outside this not-very-usefull-in-this-case SartupModule function.