Hi,
I want to make simple game based on tilemap. I’m trying to detect collision between Player (this black circle :P) and tiles (white and red squares).
Player is a sprite and tiles are “quad” (I really don’t know what’s this, I’ve tried to use plane, but in 2d view it isn’t visible (maybe that’s the problem)).
Both of them have component “Box Collider 2D” and Player has also “Rigidbody 2D” with “Is Kinematic = true”.
Code:
function OnCollisionEnter(collision : Collision){
Destroy(collision.gameObject);
Debug.Log("Booom");
}
When Player is on the tiles nothing happens (but it should destroy tiles )