MCPcopy Create free account
hub / github.com/axmolengine/axmol / initPhysics

Method initPhysics

tests/cpp-tests/Source/Box2DTestBed/Box2DTestBed.cpp:267–282  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

265}
266
267void Box2DTestBed::initPhysics()
268{
269 uint32 flags = 0;
270 flags += 1 * b2Draw::e_shapeBit;
271 flags += 1 * b2Draw::e_jointBit;
272 flags += 0 * b2Draw::e_aabbBit;
273 flags += 0 * b2Draw::e_centerOfMassBit;
274 g_debugDraw.SetFlags(flags);
275 g_debugDraw.mRatio = 8;
276 m_test->m_world->SetDebugDraw(&g_debugDraw);
277 m_test->g_debugDraw = g_debugDraw;
278 g_debugDraw.debugNodeOffset = {250, 70};
279 m_test->g_debugDraw.debugNodeOffset = g_debugDraw.debugNodeOffset;
280
281 settings.m_hertz = 60;
282}
283
284void Box2DTestBed::onDrawImGui()
285{

Callers 1

initWithEntryIDMethod · 0.95

Calls 2

SetFlagsMethod · 0.80
SetDebugDrawMethod · 0.80

Tested by

no test coverage detected