Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- b2BodyDef groundBodyDef;
- groundBodyDef.position.Set(0, 0); // bottom-left corner
- b2Body* groundBody = world->CreateBody(&groundBodyDef);
- // Define the ground box shape.
- b2PolygonShape groundBox;
- // bottom
- groundBox.SetAsEdge(b2Vec2(812.0/PTM_RATIO,310.0/PTM_RATIO), b2Vec2(-149.0/PTM_RATIO,310.0/PTM_RATIO));
- groundBody->CreateFixture(&groundBox,0);
Add Comment
Please, Sign In to add comment