Blueprint Override

ADVANCED QUESTION.
Hello, I’m not sure if it’s okey to ask such question, but here is goes.
I assume you’re planning to check for collisions in a tick function which I find rather costly since it is going to check every frame.
I wonder if it’s possible to override or use OnComponentBeginOverlap Function from blueprints of a box Component instead.
Similar to unity’s OnTriggerEnter();

Like basically I wonder if it’s possible to subscribe, override or change in any way blueprint functions provided by Unreal engine.

Generally you wouldn’t check for collisions in tick. That makes no sense given there’s the collision system. If the collisions are set up correctly, OnComponentBeginOverlap should work from either blueprint or C++

1 Like

Yes, exactly, and I wonder how can I avoid doing it. During the course, collision checks are set in Tick function. However, Unreal Engine has OnComponentBeginOverlap in Blueprints, which I assume is better when it comes to optimization. I wonder how can I subscribe to it from c++ (code), not nodes

Clarification:
In this course we are using GetOverlappingActors(Actors) function to look for collisions, but it happens in Tick and I would like to avoid doing that.

1 Like

Wait for later sections - it is covered there. This is just another way of doing it and depending on the game type, it could be valid to do it this way.

oh nice, is it possible for you to tell me which lesson is going to cover this?

You know something - I just had a quick look and can’t see anywhere where this is used at all in the course. I suspect it is maybe covered in the blueprint course instead.

Also, I understand why tick is used here, especially for grabbing - items have to be moved around so it needs to know if you’re holding or within range.

If you have access to the legacy course (UE4) there’s an escape room section and overlap events are covered in that for opening and closing doors.

I think you can get a code to access the archived course at the very end.

Privacy & Terms