Choose your operating system:
Windows
macOS
Linux
| UObjectBase
|
Module |
|
Header |
/Engine/Plugins/Experimental/ModularGameplay/Source/ModularGameplay/Public/Components/ControllerComponent.h |
Include |
#include "Components/ControllerComponent.h" |
UCLASS()
class UControllerComponent : public UGameFrameworkComponent
ControllerComponent is an actor component made for AController and receives controller events.
Name | Description | |
---|---|---|
|
UControllerComponent ( |
Name | Description | ||
---|---|---|---|
|
T * |
GetController() |
Gets the controller that owns the component, this will always be valid during gameplay but can return null in the editor |
|
T * |
GetControllerChecked() |
|
|
T * |
GetPawn() |
Controller accessors Usable for any type of AController owner, only valid if called during gameplayReturns the pawn that is currently possessed by the owning controller, will often return null |
|
T * |
GetPawnOrViewTarget() |
If this controller is possessing a pawn return the pawn, if not return the view target |
|
T * |
GetPlayer() |
PlayerController accessors Only returns correct values for APlayerController owners |
|
T * |
GetPlayerState() |
Returns the player state attached to this controller if there is one |
|
GetPlayerViewPoint |
Returns the point of view for either a player or controlled pawn |
|
|
T * |
GetViewTarget() |
Returns the actor that is serving as the current view target for the owning controller |
|
IsLocalController() |
Returns true if the owning controller is considered to be local |
|
|
PlayerTick ( |
PlayerTick is only called if the PlayerController has a PlayerInput object. |
|
|
ReceivedPlayer() |
PlayerController events These only happen if the controller is a PlayerControllerCalled after the PlayerController's viewport/net connection is associated with this player controller. |