Navigation
API > API/Runtime > API/Runtime/Engine > API/Runtime/Engine/UKismetSystemLibrary
Description
Prints a string to the log, and optionally, to the screen If Print To Log is true, it will be visible in the Output Log window. Otherwise it will be logged only as 'Verbose', so it generally won't show up.
| Name | PrintString |
| Type | function |
| Header File | /Engine/Source/Runtime/Engine/Classes/Kismet/KismetSystemLibrary.h |
| Include Path | #include "Kismet/KismetSystemLibrary.h" |
| Source | /Engine/Source/Runtime/Engine/Private/KismetSystemLibrary.cpp |
UFUNCTION (BlueprintCallable,
Meta=(WorldContext="WorldContextObject", CallableWithoutWorldContext, Keywords="log print", AdvancedDisplay="2", DevelopmentOnly),
Category="Development")
static void PrintString
(
const UObject * WorldContextObject,
const FString & InString,
bool bPrintToScreen,
bool bPrintToLog,
FLinearColor TextColor,
float Duration,
const FName Key
)
Parameters
| Name | Remarks |
|---|---|
| InString | The string to log out |
| bPrintToScreen | Whether or not to print the output to the screen |
| bPrintToLog | Whether or not to print the output to the log |
| bPrintToConsole | Whether or not to print the output to the console |
| TextColor | The color of the text to display |
| Duration | The display duration (if Print to Screen is True). Using negative number will result in loading the duration time from the config. |
| Key | If a non-empty key is provided, the message will replace any existing on-screen messages with the same key. |