Viewing Collision without Player Collision

Hello,

I have a character set up, so when the player is in VR they can look at certain objects which then highlight before they can interact with it. At the moment everything is working fine except i need to turn off the object collisions in a few of these intractable objects so the player can move around more freely. The problem is; when i turn off the object collisions it also turns off the players ability to look at the object to make it highlighted and therefore interact with it.

I noticed in the object properties there are a few different types of collision, i was wondering if there was and option so that the player can just look at the object without being physically stopped by it? Or if there is any other way to achieve this?

Thanks

You are quite correct! Through those settings you can make it so the player moves through them but can still highlight those objects!

Though it does require a bit of setup on your part.

In the dropdown for collision you can see quite a few so called collision channels. Each object can be set to interact in certain ways with other objects collisions of a certain channel.

I’m not 100% sure how exactly you do the highlighting but I’m almost certain it requires some sort of tracing or overlap.

That means you can trace for specific things while making those objects ignore your player. By default your character will have the collision preset “Pawn”. In the objects that should ignore your player, open up the “Collision presets” panel under “Collision” of the mesh or collision shape that you setup for collision, change the preset from “Pawn” to “Custom” which will leave all settings as they are but make all settings editable.

You have two basic choices here.

  1. You set the Object response of “Pawn” to “Ignore” which will make your character move right through it while still working with all or overlaps you do that aren’t of the “Object Type” “Pawn”.
  2. You set the “Collision Enabled” to “Query Only” which will disable all object collisions and make it respond only to traces that check by channel. Keep in mind that overlaps won’t work either anymore and ONLY trace by channel will work with that. Not trace by objects.

Here are two of epics resources regarding collision and collision channels:

Cheers

Thanks Erasio, that seems to be all working well :slight_smile: