{ }Blueprint → C++

Unreal Engine 5 · Blueprint → C++

Event On Component End Overlap in Unreal Engine 5 C++UE Docs

The Blueprint Event On Component End Overlap corresponds to the OnComponentEndOverlap delegate on UPrimitiveComponent, fired when another component stops overlapping this one.

Blueprint node & C++ equivalent

Header (.h)
UFUNCTION()
void OnEndOverlap(UPrimitiveComponent* OverlappedComp, AActor* OtherActor,
  UPrimitiveComponent* OtherComp, int32 OtherBodyIndex);
Bind it
MyCollision->OnComponentEndOverlap.AddDynamic(this, &AMyActor::OnEndOverlap);

What does Event On Component End Overlap do?

It triggers when an overlapping component leaves the bounds of this component, the inverse of begin overlap. Use it to reset a trigger, stop applying a status effect, or hide a prompt once the player walks away.

Note that the end overlap signature is shorter than begin overlap: it has no bFromSweep or FHitResult, because there is no meaningful hit when contact ends.

How to use it in C++

Declare OnEndOverlap(UPrimitiveComponent* OverlappedComp, AActor* OtherActor, UPrimitiveComponent* OtherComp, int32 OtherBodyIndex) and mark it with UFUNCTION(). Bind it with MyCollision->OnComponentEndOverlap.AddDynamic(this, &AMyActor::OnEndOverlap);, typically in the same place you bind begin overlap.

The OtherActor argument identifies which actor left, so you can match it against the one you stored on begin overlap.

Frequently asked questions

Does end overlap have a FHitResult parameter in C++?+

No. The OnComponentEndOverlap handler takes only OverlappedComp, OtherActor, OtherComp, and OtherBodyIndex. There is no bFromSweep or FHitResult because no hit occurs when contact ends.

Will end overlap fire if the overlapping actor is destroyed?+

Yes, destroying an overlapping actor or disabling its collision while inside the volume triggers OnComponentEndOverlap, so it is a reliable place to clean up references.

Related Collision & Overlap nodes

View all Collision & Overlap nodes →