FPlatformUserId

Handle that defines a local user on this platform.

Choose your operating system:

Windows

macOS

Linux

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/Misc/CoreMiscDefines.h

Include

#include "Misc/CoreMiscDefines.h"

Syntax

struct FPlatformUserId

Remarks

Handle that defines a local user on this platform. This used to be just a typedef int32 that was used interchangeably as ControllerId and LocalUserIndex. Moving forward these will be allocated by the platform application layer.

Constructors

Name Description

Public function

FPlatformUserId()

Create a default invalid Id

Public function

FPlatformUserId

(
    const FPlatformUserId&
)

Public function

FPlatformUserId

(
    int32 InIndex
)

Implicit conversion from user index is deprecated, use FPlatformMisc::GetPlatformUserForUserIndex

Functions

Name Description

Public function Static

FPlatformUse...

 

CreateFromInternalId

(
    int32 InInternalId
)

Explicit function to create from an internal id

Public function Const

int32

 

GetInternalId()

Returns the internal id for debugging/etc

Public function Const

bool

 

IsValid()

Sees if this is a valid user

Operators

Name Description

Public function Const

bool

 

operator!=

(
    const FPlatformUserId& Other
)

Public function

FPlatformUse...

 

operator=

(
    const FPlatformUserId&
)

Public function Const

bool

 

operator==

(
    const FPlatformUserId& Other
)

Deprecated Functions

Name Description

Public function

constexpr

 

FPlatformUserId

(
    int32 InIndex
)

Implicit conversion from user index is deprecated, use FPlatformMisc::GetPlatformUserForUserIndex

Public function Const

*

 

UE_DEPRECATED

(
    5. x,
    "Implicit conversion to user index ...,
    useFPlatformMisc::GetUserIndexForPl...
)

This should be deprecated when the online code uniformly handles FPlatformUserId