UEngine::GetFirstLocalPlayerController

Find a Local Player Controller, which may not exist at all if this is a server.

Choose your operating system:

Windows

macOS

Linux

References

Module

Engine

Header

/Engine/Source/Runtime/Engine/Classes/Engine/Engine.h

Include

#include "Engine/Engine.h"

Source

/Engine/Source/Runtime/Engine/Private/UnrealEngine.cpp

Syntax

APlayerController * GetFirstLocalPlayerController
(
    const UWorld * InWorld
)

Remarks

Find a Local Player Controller, which may not exist at all if this is a server.

Returns

first found LocalPlayerController. Fine for single player, in split screen, one will be picked.