I have player and platform (cube) and i just can’t get them to collied. I have tried OnCollisionEnter2D and OnTriggerEnter2D (in player script and platform script) and changing layers, but they just won’t collied and I can’t figger out why??? Help, please? I have sprite “bomb’s” in the same project and player collision on them works… Why won’t it work on platform?
How did you setup the colliders and the rigidbody2d’s on your objects? Without the whole context it’s difficult to say. If I had to guess I’d say from experience you either forgot to add a Rigidbody2D, you mixed 2D with 3D components or your colliders are set to be triggers and not actual colliders.
Son of a *****! You’re right. My project is setup as 2D project, but somehow platform had 3D Box Collider and not Box Collider 2D. Changed it and now it works. Thank you!
No problem. I have a whole bunch of scratches on my table where I hit my head because of these errors.