Hiya. I've gone over the docs fairly thoroughly and can't seem to find any commands for obtaining collision feedback information. The nearest I could find was EntityCollide which just confirms whether two specified entities have collided, but gives no information about the collision. This is a little sub-optimal.
If two entities collide it's necessary to first find out that those two entities have collided without testing each entity against every other entity. Blitz3D provides a collision list for each collision enabled entity, for example. Once you've discovered which entities have collided with which other entities then it's necessary to obtain information about the collision, such as the position of the collision, the collision normals, etc. For a physics based collision you also need to know how much force was involved in the collision, or at least need to have enough information available to calculate it.
Even if the physics engine is handling how the colliding bodies react physically, there's still a great many other actions that may need to be taken if two entities collide. Things such as placing a 3D sound at the collision point with a volume that reflects the force of the collision, for example. Or calculating impact damage for two colliding game objects. This all requires decent feedback about the collision event.
Seems like this is an area that's been neglected, and it really makes Purebasic useless for a wide variety of games and other projects - which is unfortunate.
Possibly the best approach for providing collision event information would be a collision event que (a linked list containing structured variables) where collision information is deposited in collision event structures. Some information that would need to be provided would be the identifiers for the two colliding entities, the position the collision occurred at, the normal direction for the collision, and the linear and angular forces involved in the collision in the case of a physics based collision (bearing in mind that different sounds, character damage, etc may need to be applied and modulated depending on the nature of the forces involved).
Entity collision information
Re: Entity collision information
Hi
There are some information on the bullet physics site regarding this :
http://www.bulletphysics.org/mediawiki- ... d_Triggers
Having this information available in a purebasic List or array (or simular) would be nice
BR
Eirik
There are some information on the bullet physics site regarding this :
http://www.bulletphysics.org/mediawiki- ... d_Triggers
Having this information available in a purebasic List or array (or simular) would be nice

BR
Eirik