Panda PhysX

@Executor:
BMCha is right, hit.getImpactNormal() should return the surface normal at the impact point. However, it is a “smoothed” normal . So far I don’t support a way to ask for either a smoothed normal or the real face normal. I will put this on my todo list.

@BMCha:
I’m afraid this is not possible, because the actor created by a controller is a kinematic actor. The error messages you see are not from my code but from the PhysX SDK itself. Setting forces on a static or kinematic actor is not allowed. Only dynamic actors can bemoved with forces. To move around a kinematic actor you must use move(). The PhysX SDK documentation has some more explanation on the different actor types. So here is what you can do:

(1) Create a dynamic actor and write you own controller code, for moving it around with forces. It’s hard, especially if you want to have all the features that PhysX controller offer, but possible. Look at the Newton, Ode or Bullet examples for how to implement a controller.

(2) Depending on how complex your forces are you can calculate a velocity change from your forces, and use actor.move() or controller.setLocalSpeed() accordingly.

enn0x