main-loop.nv
· 808 B · Text
Sin formato
Playground
|_| The main application loop
|run main loop|
, start polling inputs
, poll input
, handle input
, run current frame
|start polling inputs|
, @start polling
|poll input|
, @poll input
|handle input, @no events left|
|handle input|
, handling input
, poll input
, handle input
|run current frame, @event quit|
, @quit love
|run current frame|
, step timer
, clear the screen
, update scene state
, draw scene
, present current frame
, sleep for 1ms
, next cycle
| step timer | @step timer
| clear the screen | @clear screen
| update scene state | updating scene
| draw scene | drawing scene
| present current frame | @present
| sleep for 1ms | @sleep
| next cycle | run main loop
1 | |_| The main application loop |
2 | |run main loop| |
3 | , start polling inputs |
4 | , poll input |
5 | , handle input |
6 | , run current frame |
7 | |
8 | |start polling inputs| |
9 | , @start polling |
10 | |
11 | |poll input| |
12 | , @poll input |
13 | |
14 | |handle input, @no events left| |
15 | |
16 | |handle input| |
17 | , handling input |
18 | , poll input |
19 | , handle input |
20 | |
21 | |run current frame, @event quit| |
22 | , @quit love |
23 | |
24 | |run current frame| |
25 | , step timer |
26 | , clear the screen |
27 | , update scene state |
28 | , draw scene |
29 | , present current frame |
30 | , sleep for 1ms |
31 | , next cycle |
32 | |
33 | | step timer | @step timer |
34 | | clear the screen | @clear screen |
35 | | update scene state | updating scene |
36 | | draw scene | drawing scene |
37 | | present current frame | @present |
38 | | sleep for 1ms | @sleep |
39 | | next cycle | run main loop |