您需要创建两个夹具 - 一个是精灵大小(并且精灵应该以该夹具为中心),第二个移动到圆的边缘(您当前的碰撞夹具)
BodyDef bodyDef;
...
Body body = world.createBody(bodyDef);
FixtureDef circleFixture = new FixtureDef();
FixtureDef collisionFixture = new FixtureDef();
CircleShape circle = new CircleShape();
circle.setRadius(spriteRadius);
circleFixture.shape = circle;
//same for collision fixture with proper shape - (0,0) i a center of circle
float[] vertices = new float[]{x1, y1, x2, y2...};
ChainShape chain = new ChainShape();
chain.createLoop(vertices);
fixtureDefs.peek().shape = chain;
现在,如果您需要将碰撞夹具保持在圆的边缘,只需定义将其放置在那里的点 - 例如半径为 2 顶点的圆
{5, -1, 6, 0, 5, 1, 4, 0}
会给出类似的东西
旋转后它应该表现得像
当然,您需要在圆形夹具的中心渲染您的精灵