For example, create an actor called Bullet with tag “BulletTag”, then create another actor called Pawn with tag “PawnTag”. When Bullet overlaps Pawn, it checks that if the other actor has tag called “PawnTag”. If true, Bullet is destroyed immediately. Pawn has the similar logic. There are the Blueprints of Pawn and Bullet:
However, When Bullet overlaps Pawn, I don’t know of which actor The Event ActorBeginOverlap fires first, and no matter which Event fires first, you will aways get an error like this:
That means you should not change any variable and destroy any actor immediately when Event ActorBeginOverlap fires, otherwise it is possible that one of the two overlaped actors will get wrong information of the other actor.
My solution is to store the variables first, then delay for 0 second, after that I can do some changes. like this:
But if there are many variables to store, it will cost too much space. So I think it’s a bad way to solve this question. Is there any other way to do some changes immediately when Event ActorBeginOverlap fires?