Search Issue Tracker
By Design
Votes
24
Found in
4.3.0f4
Issue ID
575251
Regression
No
Rigidbody2d with kinematic rigidbody will not cause OnTriggerEnter2d
To reproduce:
1. Create two 2D cubes with colliders 2d
2. Attach a rigidbody 2D to one of the cubes and make the other cube a trigger
3. Attach a script with OnTiggerEnter2D (and some kind of debug message) to the rigidbody cube
4. Enter play mode and move the cube into the other cube - the debug message should get printed
5. Change the rigidbody 2d to kinematic - the debug message is no longer printed, OnTriggerEnter2d is no longer being called
Explanation: kinematic bodies (specifically colliders attached to those bodies) only collide with dynamic bodies.
The allowed collisions for body types are therefore:
Kinematic can collide with Dynamic
Dynamic can collide with Static, Dynamic & Kinematic
Static can collide with Dynamic
Comments (44)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Build fails with compiler errors when switching scripts GUIDs
- Many references for Animator elements redirect to missing pages
- User gets "EndLayoutGroup: BeginLayoutGroup must be called first." error during Xcode selection canceling
- "Unable to use a named GUIStyle without a current skin" error appears in the Console when entering the Play Mode in a project with specific layout
- [D3D12][XR] SRP Foveation foveated rendering on Windows platform not working when Graphics API is set to D3D12
Bamboy
Dec 08, 2013 16:30
I just spent around 10 hours making something that was relying on OnTriggerEnter2D to function properly. Please fix this ASAP. (+10 votes)
Tortuap
Dec 07, 2013 23:56
Agree too. Is it by design because they miss the feature and now they fear about developers complaining about the change ? We wont complain about a change if it helps things to be iso between 2D / 3D and if it makes things easier. Why would I put a rigid body and hacking it to disable the physics for getting collision detection to work ?
MacTwiste
Dec 05, 2013 18:09
Why is this marked as By Design?
It's a pretty common case to have kinematic objects activate triggers. LIke a player entering an area to trigger an event, for instance. Do you advise using 3D collision instead or are there plans to fix this?
Andrige_
Dec 03, 2013 13:11
Agreed. My projectile system has stopped working due to this bug.