I want to make some actors in my level block the player from passing through them but allow npcs to pass through them, how do i set up the collision to do that?
Easiest way is to use a combination of custom object channel and collision presets (found under project settings>collision).
One way to do it:
Create a new object channel, call it something like “BlockPlayer”, set it to BLOCK
Set the collision on you blocking actor to Custom and object type to “Block Player”
On anything you want to pass through the block (like your NPCs), add the node “Set Collision Response to Channel”:
Connect that node to how you want to activate it.
Always on, hook it up to On Begin Play, or get creative if you want the block actor to block NPCs until a certain time or an event has occured.
Definitely custom object channel with custom collision setups
This works great, thank you!
The solution found worked correctly, but there is a detail that was struggling.
I was using a blocking volume to block or not and it was affecting navigation (so NPC never walked through it).
It was needed to set “Can Ever Affect Navigation” as false.