Collision works when character walks into object, but not when object runs into character

Hey all, I’m having issues with collision, specifically in Paper2d. I noticed this behavior originally while trying to get sprite collision to work, so I made a more general example using a box and capsule.

I have 2 characters, char1 and char2. Char2 has a box collision attached to its blueprint. When I control char1 and walk towards char2, I collide with the box and stop. However, when I control char2 and walk towards char1, the box doesn’t collide.

Here’s a video showcasing this: Collision Issue - YouTube

The box is using BlockAllDynamic for its collision, and char1’s capsule is using Pawn. Changing the box to Pawn doesn’t work, either.

How would I go about fixing this so that the box collides all the time, just like the capsule component?

what happens if you change them both to be BlockAllDynamic?

I can point you in the right direction but from then on my guess is as good as yours.
When you move a character with the Movement Component (or in any other way in fact) there are several things that happen

  1. A ray cast /sphere cast is preformed to see if the character will hit something between frames
  2. The character’s root component is moved (in your case - the inherited capsule) to the place of the hit
  3. All other components are teleported in their respected places around the root component

The box however should fire an overlap/hit event. It just does not affect the movement as the movement component only “listens” to the capsule’s hit events. You should check if the box hits something doing the steps above before moving the character.

Same thing, except the character doesn’t get pushed. The box still goes through, though.

I’ve looked at how the movement component works more and I think I’m starting to understand the issue? My understanding as of right now is that the movement component is wholly in charge of whether the character moves or is blocked by collision. Since the capsule is built into the movement component, it can account for collisions as movement occurs, but it won’t account for other objects. That seems odd, though. I would imagine there would be a higher level system determining whether an actor actually moves or collides.

That’s all the info I need. Thanks!