Fixture(Body body, FixtureDef def) { this.body = body; shape = def.getShape().clone(); userData = def.getUserData(); density = def.getDensity(); friction = def.getFriction(); restitution = def.getRestitution(); isSensor = def.isSensor(); filter.set(def.getFilter()); // Reserve proxy space int childCount = shape.getChildCount(); proxies = new FixtureProxy[childCount]; for (int i = 0; i < childCount; i++) { proxies[i] = new FixtureProxy(); } }
Fixture(Body body, FixtureDef def) { this.body = body; shape = def.getShape().clone(); userData = def.getUserData(); density = def.getDensity(); friction = def.getFriction(); restitution = def.getRestitution(); isSensor = def.isSensor(); filter.set(def.getFilter()); // Reserve proxy space int childCount = shape.getChildCount(); proxies = new FixtureProxy[childCount]; for (int i = 0; i < childCount; i++) { proxies[i] = new FixtureProxy(); } }