IronWarrior / SuperCharacterController

Unity custom character controller
MIT License
759 stars 207 forks source link

Trigger collisions #24

Open hudecv opened 8 years ago

hudecv commented 8 years ago

Hey dude, the character controller is really great stuff, but currently there is no trigger detection. My character uses triggers in the world to run interactions and scripts, but without trigger detection, it's a no go for me. Do you plan on adding trigger detection?

IronWarrior commented 8 years ago

Hey hudecv, At line 341, you'll see:

if (col.isTrigger)
                    continue;

Deleting this will allow it to be pushed back against triggers. In the next update I'll add an option to choose whether triggers should be considered or not. Thanks for the comment, Erik

hudecv commented 8 years ago

Oh, I didn't see that. I've made a workaround for it, along with a couple of edits to make the character movement work with my mouse look system. It's really great plugin. May I ask why you need to set the Walkable attribute on the controller? Why not detect this through the physics layers?