Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

how to Change the shape of body dynamically #51

Open
a6965921 opened this issue May 23, 2022 · 1 comment
Open

how to Change the shape of body dynamically #51

a6965921 opened this issue May 23, 2022 · 1 comment

Comments

@a6965921
Copy link

const gravity = new b2Vec2(0, 10);

world = new b2World(gravity);

const bd_ground = new b2BodyDef();

const ground = world.CreateBody(bd_ground);
const shape = new b2EdgeShape();
var xx=new b2Vec2(3, 4)
shape.SetTwoSided(xx, new b2Vec2(6, 7));
ground.CreateFixture(shape, 0);
@V-HuangChunMing
Copy link

you can destory this fixture and recreate

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants