MCPcopy Create free account
hub / github.com/bfbbdecomp/bfbb / xEntMotionDebugIPad

Function xEntMotionDebugIPad

src/SB/Core/x/xEntMotion.cpp:1353–1390  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1351}
1352
1353static void xEntMotionDebugIPad(xEntMotion* xem)
1354{
1355 if (gDebugPad->pressed & 0x20)
1356 {
1357 *(volatile S16*)(&dbg_idx) = *(volatile S16*)(&dbg_idx) + 1;
1358 if (*(volatile U16*)(&dbg_num) >= *(volatile S16*)(&dbg_idx))
1359 {
1360 *(volatile S16*)(&dbg_idx) = 0;
1361 }
1362 }
1363 if (gDebugPad->pressed & 0x80)
1364 {
1365 *(volatile S16*)(&dbg_idx) = *(volatile S16*)(&dbg_idx) - 1;
1366 if (*(volatile S16*)(&dbg_idx) < 0)
1367 {
1368 *(volatile S16*)(&dbg_idx) = *(volatile U16*)(&dbg_num) - 1;
1369 }
1370 }
1371 if (gDebugPad->pressed & 0x10000)
1372 {
1373 if (xem->owner != NULL)
1374 {
1375 xEntReset(xem->owner);
1376 }
1377 xEntMotionReset(xem, g_xSceneCur);
1378 }
1379 if (gDebugPad->pressed & 0x20000)
1380 {
1381 if (xEntMotionIsStopped(xem))
1382 {
1383 xEntMotionRun(xem);
1384 }
1385 else
1386 {
1387 xEntMotionStop(xem);
1388 }
1389 }
1390}

Callers 1

xEntMotionDebugCBFunction · 0.85

Calls 5

xEntMotionIsStoppedFunction · 0.85
xEntMotionRunFunction · 0.85
xEntMotionStopFunction · 0.85
xEntResetFunction · 0.70
xEntMotionResetFunction · 0.70

Tested by

no test coverage detected