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 /
avatar image
5
Question by vinfang · Nov 22, 2013 at 12:22 AM · rigidbodycollider

Can Rigidbody 2D collide with 3D Colliders?

Reading the extra details that this page talks about the colliders, http://docs.unity3d.com/Documentation/Components/class-Rigidbody2D.html, it seems that this 2d Rigid body can only collide with other 2D objects and not 3D objects. I've tried to make the player using a rigid 2d body collide with the regular 3d box collider but it keeps passing through. It does collide with the 2d box collider object below so I know I'm using the rigidbody 2d correctly at least.

Does anyone have any input on this?

Comment
Add comment
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

2 Replies

· Add your reply
  • Sort: 
avatar image
19

Answer by MiaN KhaLiD · Jan 17, 2014 at 07:56 AM

I stumbled upon this issue myself recently, and have found out that its not possible for a 2D object to collide with 3D object and vice versa. Reason being unity uses PhysX for 3D and Box2D for 2D, which are exclusive of each other.

So what options do we have, if we want a hybrid

There are 2 ways we can achieve collision between the 2 systems:

  1. To your 3D object add an empty game object as a child, with RigidBody2D (GravityScale set to 0) & a BoxCollider2D matching the width of the 3D Object. Then receive the collision event in the OnCollisionEnter2D(Collision2D collision) function.

  2. Or you can add a RigidBody and a 3D Collider (say BoxCollider) to your 2D object and receive the collision event in the OnCollisionEnter (Collision collision) function.

Hope it answers the question :)

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 J0hn4n · Jun 09, 2017 at 08:59 PM

Or just make 2 childs one to handle 2d collision events and another one to handle 3d events, EZ. another alternative its just handle your own system already if you dont need physic its EZ too.

Comment
Add comment · Show 2 · 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 KeiranGlynn · Jul 20, 2018 at 05:50 AM 3
Share

Yeah bro, gg EZ, man! Real hip cool idea that doesn't work! EZ, peace out!

avatar image leonhogan1 · Mar 08 at 03:42 AM 0
Share

yeah thats not a very solid solution

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

22 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

Related Questions

Avoid one gameObject skin in another gameObject 2 Answers

how to Apply Gravity at Run time ..????????? 2 Answers

OnCollisionEnter not triggering when two rigidbody collide via Instantiate 1 Answer

Does collider size affect performance? 1 Answer

My Objects are falling through the floor.. 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