Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
This question was closed Jun 29, 2014 at 11:48 PM by TacticalBlank for the following reason:

Question is off-topic or not relevant

avatar image
1
Question by TacticalBlank · Jun 27, 2014 at 08:33 PM · physicstriggercharactercontrollerboxcollider

Can a character controller collide with a trigger?

I have a player that uses a character controller and a box collider that has is trigger selected. I want it so when the player hits the box collider, it moves the camera. However, this does not seem to be working at all. Is it even possible for a character controller to collide with a trigger, and if so, is there any specific way I would go about doing this?

Comment
Add comment · Show 2
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image instruct9r · Jun 27, 2014 at 09:32 PM 0
Share

I have a character, with CharacterController and it collides with trigger without any problem. Don't know why you woud have a problem with that... $$anonymous$$aybe the problem is somewhere else.. Layer?

Can you show some piece of code?

avatar image TacticalBlank · Jun 29, 2014 at 11:47 PM 0
Share

Sorry, it seems I had a completely unrelated problem. Turns out you can't do input in the OnTriggerEnter function. Derp.

2 Replies

  • Sort: 
avatar image
1

Answer by Ares121 · Jun 27, 2014 at 09:49 PM

I'm fairly new with Unity but I've been messing with triggers a bit as of late. If you want a reaction upon collision you would need to use a function like OnCollisionEnter. If you are using a trigger it will not collide with the trigger collider, but it will tell the code to behave however you have told it to with the function OnTriggerEnter. Perhaps if you post some of your code one of the pros can provide a more detailed answer for you.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
0

Answer by MrReynevan2 · Jun 27, 2014 at 09:49 PM

Generally, triggers are used to trigger something, not to check for collisions. If you're looking for simple way to fix your problem, try making empty GameObject, and set it as child of obiect with box collider.

For the parent, set "Is Trigger". For the child (recently created gameobject) add "Box Collider", and set i about the size of the parent's colider. Don't check "Is Trigger". This way you'll be able to both trigger actions, and check for collisions. It's simple, not perfect though.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Follow this Question

Answers Answers and Comments

24 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

CharacterController with BoxCollider 1 Answer

How do I detect when two CharacterControllers collide? 0 Answers

Bullets colliding with Character Controller 3 Answers

Need help with Raycasting 1 Answer

How can I make the Player [CharController] interact with Physic Materials 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges