The log system is not intended to provide runtime information to the program itself. The user has full control over what log messages are and are not generated.
What are you trying to accomplish, more specifically? If you’re trying to extract some gameplay information, use an in-engine messaging system to get the data to where it needs to go. If you’re trying to provide a log window in-game while paying the game, for visibility, then make an in-memory log sink that you can read yourself. Start lookging at FMsg in LogMacros.h and look at extending the FOutputDevice objects. You can easily wrap your own implementation that makes a copy available on top of the ones that are there.
You really only need to override the Serialize() function in your subclass/proxy class…
That’s what i want to do! i’d like to create my own messaging system which can get [ProjectName].log in game.
i think override the Serialize() would work! Could you explain it more specifically? i know LogMacros.h is where UE_LOG is, but i never tried to create my subclass of FOutputDevice.
If i created my subclass of FOutputDevice, would it affect the original FOutputDevice? Do i need to create an instance of my FOutputDeivce subclass?
You need to create a subclass of FOutputDevice, and then assign an instance of it as the log device being used. Just trace through the code in the logger, it’s not super complicated.