[] Collision doesn't get Hit Event

Hello,

I’m having a problem involving collision in the program (which is built in UE4). As I’m not sure if the problem is something defined in or if it’s a UE4 bug, I decided to post it here :slight_smile: I really appreciate any tip!

Basically the problem is this: I have two actors, a pedestrian and a vehicle. I’m generating several scenarios where they collide. The pedestrian crosses the street in a straight line and the vehicle collides with him.

For the same speed, when the pedestrian collides with the vehicle before the middle of the vehicle, the collision is recognized, generating a “Hit Event” that is sent to an element called “collision sensor” that returns information from the actors involved in the collision. (That is what i had figure out about how the things works in ). But when the pedestrian collides with the vehicle after its middle, the “collision sensor” is not recognizing any collision. But there is no overlap, that is, the actors are blocking each other as expected.

My guess is that for some reason the “Hit Event” is not being generated and therefore the collision sensor is not returning to me that there was a collision.

This happens at different speeds for the vehicle (10 to 60).

Another interesting fact is that if I reverse the position of the pedestrian, thus changing what is before and after the middle of the vehicle. Where before the collision was recognized, it ceases to be and vice versa. The images below should help clarify the issue.

350069-129367066-9b9af4b6-6566-48b3-9323-924211874802.png

350070-129366637-970154b8-94ea-4e8e-b945-d0750a3b71ce.png

I’ve tried several suggestions:

1 - Enable CCD;

2 - Changed pedestrian and vehicle collision settings;

3 - Generate a more detailed collision mesh for the vehicle;

but so far nothing has resolved. If anyone has any ideas, I would be very grateful.

Hi,

I opened the Output.log and added at my vehicle blueprint a print function for every hit event, to check if the hit event is being generated. And was i supposed, it’s not. Here the output when the collision is recognized:
LogTemp: Loaded OpenDrive file ‘D://Unreal//Content/EuroNCAP_VRU/Maps/EuroNCAP_VRU/OpenDrive/EuroNCAP_VRU.xodr’
LogCarla: Spawning actor ‘vehicle.tesla.model3’
LogCarla: Spawning actor ‘walker.pedestrian.0001’
LogCarla: Spawning actor ‘sensor.other.collision’
LogCarla: Spawning actor ‘sensor.camera.rgb’
Cmd: g.TimeoutForBlockOnRenderFence 300000
g.TimeoutForBlockOnRenderFence = “300000”
LogBlueprintUserMessages: [BP_Sky_2] Altitude: 45.0
LogBlueprintUserMessages: [BP_Sky_2] Fog: 2.0
LogBlueprintUserMessages: [BP_Sky_2] Level:
LogUdpMessaging: Warning: UDP messaging encountered an error. Auto repair routine started for reinitialization
LogUdpMessaging: Warning: UDP messaging encountered an error. Auto repair routine started for reinitialization
LogUdpMessaging: Warning: UDP messaging encountered an error. Auto repair routine started for reinitialization
LogBlueprintUserMessages: [BP_TeslaM3_C_5] Collision

And when the collision is not recognized, i don’t get the “Collision” text:
Even when they collide.

Hi, did you make sure that you have “Simulation Generates Hit Events” checked on your collisions? Otherwise they will still collide but won’t execute any HitEvent.


If you haven’t already you could try to read through this here Collision Overview | Unreal Engine Documentation

Hi Thanks for the reply!

Yes i have checked already “Simulation Generate Hit Events”. And as sometimes it returns the Hit Event and sometimes not, I think if it was the “Simulation Generate hit Events” that was not activated it will not generate the hit event in any situation, right?

Do you any other idea, what can be ?

1 Like