Added flag for activating or deactivating aabb test