Prev: 33343 Up: Map Next: 33368
33354: Limit Frame Rate
Called at the beginning of each game loop. Setting a higher pause value will slow the game down.
LimitFrameRate 33354 LD A,(24146) Return if FrameUpdated is is not marked as being updated.
33357 AND A
33358 RET NZ
33359 LD HL,192 Introduce a counter (0192) for a slight pause.
LimitFrameRate_Loop 33362 DEC HL Decrease counter by one.
33363 LD A,L Keep jumping back to LimitFrameRate_Loop until the counter is zero.
33364 OR H
33365 JR NZ,LimitFrameRate_Loop
33367 RET Return.
View the equivalent code in;
Prev: 33343 Up: Map Next: 33368