i need some code for checking collision bettween the bullets and the player
if u have some please send
it's an urgent problem
please help...
any idea about dynamic collisions???
Easy. Read the help, that's what I did.
Here's a snippit from my code, where I do bounding box collision between the "sydney" model, and the "faerie" model;
Something that tripped me up at first is; you can't used getBoundingBox, because it only returns the size and position the bounding box was when the model was loaded. You need to use getTransformedBoundingBox, to get the one that actually represents where they really are and their current size.
Here's a snippit from my code, where I do bounding box collision between the "sydney" model, and the "faerie" model;
Code: Select all
if (sydney->getTransformedBoundingBox().intersectsWithBox(faerie->getTransformedBoundingBox())){
printf("collision\n");
}