How To Simply Print a log

I want to print some log during runtime.
I have searched for some documentation. It says I must declare the log class first. sometimes I only want to print a very simple string and don’t want to do any extra works.
GEngine->AddOnScreenDebugMessage() Seems to be a good way, But sometimes I don’t want it to be shown on screen(only show in the output console).
Just like qDebug() in Qt and OutputDebugString() in VisualStudio, I can use Just a simple code to print some log.
Can anyone help me?

UE_LOG(LogTemp, Warning, TEXT(“Your message”));

Thanks,It seems useful.

Tip: You can filter by warning to show only warning logs, and you’ll get a clean log.

for people in the future, the quotation marks in the solution are apparently automatically turned into weird quotation marks by the forum itself. It causes errors. This is correct:

UE_LOG(LogTemp, Warning, TEXT("Your message"));
1 Like