How to do bone collisions ?
Blitz3D Forums/Blitz3D Programming/How to do bone collisions ?
| ||
Hi, I have been working on an experimental beat em up and have run into a problem. I was wondering if some one out there would be kind enough to help me ? I am using the ninja.b3d model, however I cannot get the meshesintersect command to work with any of the bones. I mean it works fine if two characters(3ds) with multiple meshes collide for e.g. the hand and chest but not for a boned single mesh. Can anyone tell me of an alternative method ? Thanks. |
| ||
You could go about it by putting pivots at each joint, then checking for collisions on those pivots. |
| ||
Collision spheres at each bone joint using EntityDistance() is probably your best option. |
| ||
Bonecollisions... http://www.klik2.dk/boner.mpeg Andy |
| ||
Thanks for that Andy... hehe A bone is really a pivot, so you should not need to put a pivot there. I would go with masterbeaker's suggestion. |
| ||
Thank you very much guys. Attaching a sphere to each bone as a collision point seems to be the answer. |
| ||
this is where ragdoll come in handy |
| ||
Although it sounds like you've already figured out your question/problem, I would also recommend Masterbeaker's approach. Depending on your needs however it may be simpler to use the built-in collision detection system by setting EntityRadius for bones. Note however that this would result in bones being deflected when collisions are detected. The reason MeshesIntersect didn't work is because bones don't have a mesh to intersect with. |