我知道杀死或添加b2body会在联系时崩溃。但是,如果我只改变身体过滤器?
if (box2dSubFixture) {
b2Filter filter = box2dSubFixture->GetFilterData();
filter.maskBits = BOX2D_MaskBits_NONE;
filter.categoryBits = BOX2D_CategoryBits_NONE;
box2dSubFixture->SetFilterData(filter);
}