I just have a few questions about the code, specifically, the values you use to set the objects in the code?
for example like :
Code: Select all
b2FixtureDef fd;
fd.friction = 2.000000029802322e-01f;
fd.restitution = 0.000000000000000e+00f;
fd.density = 1.000000000000000e+00f;
fd.isSensor = bool(0);
fd.filter.categoryBits = uint16(1);
fd.filter.maskBits = uint16(65535);
fd.filter.groupIndex = int16(0);
b2PolygonShape shape;
b2Vec2 vs[8];
vs[0].Set(2.000000000000000e+01f, -5.000000000000000e-01f);
vs[1].Set(2.000000000000000e+01f, 5.000000000000000e-01f);
vs[2].Set(-5.485061645507812e+01f, 5.000000000000000e-01f);
vs[3].Set(-5.485061645507812e+01f, -5.000000000000000e-01f);
shape.Set(vs, 4);
fd.shape = &shape;
bodies[1]->CreateFixture(&fd);
Anyway thanks for the tutorials! Keep up the great work ^_^