RealDocs

APawn::ReceivePossessed

function Engine Blueprint Since 4.0
#include "GameFramework/Pawn.h"
Access: public Specifiers: UFUNCTIONBlueprintImplementableEventBlueprintAuthorityOnly

Description

Blueprint event fired on the server/authority when a controller possesses this pawn. Implement in Blueprint to react to possession without subclassing in C++.

Caveats & Gotchas

  • BlueprintAuthorityOnly — this event will NOT execute on clients in a multiplayer game, only on the server or in standalone. If you need client-side logic on possession, use `ReceiveControllerChanged` instead.
  • This is called from inside `PossessedBy`; if you override `PossessedBy` in C++ and do not call `Super::PossessedBy()`, this event will never fire.

Signature

void ReceivePossessed(AController* NewController)

Parameters

Name Type Description Default
NewController AController* The controller that has just possessed this pawn.

Return Type

void

Example

React to possession by casting the new controller to PlayerController Blueprint
Event Receive Possessed New Controller Cast To Player Controller Object Cast Failed As Player Controller As Player Controller Print String In String Player now controls this pawn! Player now controls this pawn!
Edit Blueprint graph React to possession by casting the new controller to PlayerController
Drag node headers to move · Drag from an output pin to an input pin to connect · Scroll to zoom · Right-click for actions

Version History

Introduced in: 4.0

Version Status Notes
5.6 stable

Feedback

Was this helpful?

Suggest an edit

Select a field above to begin editing.