Skip to content
Snippets Groups Projects

Adding brackets to do complete nullptr check

Merged Jan Delember requested to merge fix/HUD_nullptr_check into develop
1 file
+ 3
1
Compare changes
  • Side-by-side
  • Inline
@@ -64,8 +64,10 @@ void UniversalLoggingImpl::OnPostActorTick(UWorld* World, ELevelTick LevelTick,
@@ -64,8 +64,10 @@ void UniversalLoggingImpl::OnPostActorTick(UWorld* World, ELevelTick LevelTick,
return;
return;
auto HUD = PlayerController->GetHUD();
auto HUD = PlayerController->GetHUD();
if (HUD)
if (HUD)
 
{
HUD->AddPostRenderedActor(On_Screen_Log_Actor); // Doing this every tick seems excessive (AddPostRenderActor checks for duplicates, though)
HUD->AddPostRenderedActor(On_Screen_Log_Actor); // Doing this every tick seems excessive (AddPostRenderActor checks for duplicates, though)
HUD->bShowOverlays = true; // Yuck, but necessary as otherwise the Actor's PostRenderFor method is not called.
HUD->bShowOverlays = true; // Yuck, but necessary as otherwise the Actor's PostRenderFor method is not called.
 
}
}
}
ILogStream* UniversalLoggingImpl::NewLogStream(const FString StreamName)
ILogStream* UniversalLoggingImpl::NewLogStream(const FString StreamName)
Loading