Navigation
API > API/Runtime > API/Runtime/Engine > API/Runtime/Engine/UGameplayStatics
Description
Returns the player controller with the specified physical controller ID. This only works for local players.
| Name | GetPlayerControllerFromPlatformUser |
| Type | function |
| Header File | /Engine/Source/Runtime/Engine/Classes/Kismet/GameplayStatics.h |
| Include Path | #include "Kismet/GameplayStatics.h" |
| Source | /Engine/Source/Runtime/Engine/Private/GameplayStatics.cpp |
UFUNCTION (BlueprintPure, Category="Game",
Meta=(DisplayName="Get Local Player Controller From Platform User", WorldContext="WorldContextObject", UnsafeDuringActorConstruction="true"))
static APlayerController * GetPlayerControllerFromPlatformUser
(
const UObject * WorldContextObject,
FPlatformUserId UserId
)
Parameters
| Name | Remarks |
|---|---|
| ControllerID | Physical controller ID, the same value returned from Get Player Controller ID |