Sorry to necropost, but this issue is not in fact resolved. Judging from this thread, and from my own exhaustive efforts, there is no way to create a sensor that detects an AWPKinematicCharacterController without blocking it.
Creating one like so:
var charShape:AWPCapsuleShape = new AWPCapsuleShape(10, 50);
charObject.collisionFlags = AWPCollisionFlags.CF_CHARACTER_OBJECT;
charController = new AWPKinematicCharacterController(charObject, 0.1);
physicsWorld.addCharacter(charController);
and adding a collision handler like so:
physicsWorld.collisionCallbackOn = true;
charObject.addEventListener(AWPEvent.COLLISION_ADDED, charCollisionAddedHandler, false, 0, true);
and a sensor like so:
var sensorShape:AWPBoxShape = new AWPBoxShape(100, 50, 100);
var sensor:AWPRigidBody = new AWPRigidBody(sensorShape);
sensor.collisionFlags = AWPCollisionFlags.CF_NO_CONTACT_RESPONSE;
physicsWorld.addRigidBody(sensor);
I can see the sensor and my controller’s capsule using AWPDebugDraw, and when I run into the sensor, charCollisionAddedHandler fires as I expect. However, the sensor stops me from passing through just like a solid object, despite it’s collisionFlags.
When I spawn other dynamic objects in the scene, they pass through the sensor as I’d expect. Only my capsule is blocked by the sensor. I’ve tried using an AWPCollisionObject and an AWPGhostObject as a sensor instead of a an AWPRigidBody, and the results are the same.
Looking at the C++ bullet engine forums, I found a similar problem with btKinematicCharacterController, with earlier versions of bullet. What version of bullet does awayphysics use? Perhaps the most recent version of bullet (2.82 as of now) fixes this bug, and awayphysics would benefit from recompiling bullet.
FYI according to bulletphysics.org, 2.82 is likely to be the last version before bullet 3 is released, and bullet 3 runs on the GPU and therefore will not be usable by awayphysics.