MCPcopy Create free account
hub / github.com/diasurgical/devilution / game_loop

Function game_loop

Source/diablo.cpp:1632–1649  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1630}
1631
1632void game_loop(BOOL bStartup)
1633{
1634 int i;
1635
1636 i = bStartup ? 60 : 3;
1637
1638 while (i--) {
1639 if (!multi_handle_delta()) {
1640 timeout_cursor(TRUE);
1641 break;
1642 } else {
1643 timeout_cursor(FALSE);
1644 game_logic();
1645 }
1646 if (!gbRunGame || gbMaxPlayers == 1 || !nthread_has_500ms_passed(TRUE))
1647 break;
1648 }
1649}
1650
1651// Controller support:
1652extern void plrctrls_after_game_logic();

Callers 1

run_game_loopFunction · 0.85

Calls 4

multi_handle_deltaFunction · 0.85
timeout_cursorFunction · 0.85
game_logicFunction · 0.85
nthread_has_500ms_passedFunction · 0.85

Tested by

no test coverage detected