Hello,
How do you determine what an entity has collided with? I tried to use an if statement inside fixture.onBeginContact but it didnt allow that? I have the following:
CircleCollider {
id: ufoCollider
radius: ufoSprite.width/2
anchors.fill: ufoSprite
collisionTestingOnlyMode: true
categories: Circle.Category2
collidesWith: Circle.Category1 || Box.Category1
fixture.onBeginContact: {
ufo.removeEntity()
console.log("KollisionUfo" + Math.random())
}
}
And i want to determine when this ufo collide with my ship.
Thanks
/Isak