Description
Adds an actor to the pawn's movement collision ignore list so the pawn can pass through it during movement sweeps. Commonly used when boarding a vehicle, carrying an object, or temporarily clipping through a spawner.
Caveats & Gotchas
- • This only affects movement sweeps performed by the pawn's movement component (e.g. the capsule during UCharacterMovementComponent::MoveAlongFloor). It does NOT suppress overlap or hit events — the actors can still trigger OnComponentBeginOverlap against each other.
- • The ignore list is stored on the RootComponent's MoveIgnoreActors array. If you swap the RootComponent at runtime the list is lost.
- • Duplicate entries are not deduplicated; calling this twice with the same actor adds it twice, and you must call MoveIgnoreActorRemove twice to fully restore collision.
Signature
ENGINE_API void MoveIgnoreActorAdd(AActor* ActorToIgnore); Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| ActorToIgnore | AActor* | The actor whose collision should be ignored by this pawn's movement sweeps. | — |
Return Type
void Example
Ignore a vehicle hull while boarding C++
void AMyCharacter::StartBoarding(AVehicle* Vehicle)
{
// Prevent movement sweeps from blocking against the vehicle hull
MoveIgnoreActorAdd(Vehicle);
// Attach and begin boarding animation...
}
void AMyCharacter::FinishBoarding(AVehicle* Vehicle)
{
MoveIgnoreActorRemove(Vehicle);
} See Also
Tags
Version History
Introduced in: 4.0
| Version | Status | Notes |
|---|---|---|
| 5.6 | stable | — |
Feedback
Was this helpful?