I’ve got a problem with overlapping GhostControllers. If I activate debugmode, the collisionshapes seem to be okay, but they’re triggering overlaps even if they don’t seem like touching each other. Here’s a video of my problem:
Even though reading the collisions is inside the simpleUpdate() I also tried using PhysicsTickListener with the following control but it gave me exactly the same results.
[java]public class GhostControl2 extends GhostControl implements PhysicsTickListener{
I moved to raycasting and got pretty decent performance. I guess I could get even better if I cast the rays against more simple versions of the geometries. But thanks for confirming that there really is something with the ghostControl.
I’m using the standard one. The performance of the game actually improved a tiny bit even though I’m using the high poly meshes because updating the phyiscs space and constantly attaching new physics objects consumed a lot of performance.
you definitely move the spatial and the ghost control moves with it (just checked for confirmation). And cracked open a quick testcase to illustrate the problem. While small, there is a gap where collisions are being detected. And this is apparent in both ghost/ghost and ghost/rigidbody collisions.
“GhostObject can keep track of all objects that are overlapping. By default, this overlap is based on the AABB. This is useful for creating a character controller, collision sensors/triggers, explosions etc.”
If its based on AABB, doesn’t that imply that the collision shape is ignored?
I know that bullet by default has a small margin when detecting collision … Perhaps that is it? Can you try it with AABB collision shape maybe and see if the issue appears?
The gap is definitely smaller with the BoxCollisionShape, although the camera angle is different to the first one. Shown below there is no collision yet: