Is it possible to access data from a collision, such as point of collision and impact force? I am trying to simulate a "drop test" in Blender and cannot figure out how to access the information. As of now, I am trying to use the Blender game engine and python.
By using collision callbacks you can retrieve the hit object, point and normal (not sure about how to retrieve the impact force though). See the API reference for more info. Example file below.
def my_callback(object, point, normal): ''' Do whatever you want with your collision data ''' print('Hit by', object.name, 'at', point, 'with normal', normal) def register_callback(cont): ''' Run this with an always sensor (tap enabled) when the game starts ''' own = cont.owner if not my_callback in own.collisionCallbacks: own.collisionCallbacks.append(my_callback)