← B351 Draw the score and high-score readouts Map B396 → Add the points to the score and redraw it
B37A: Add the pending score to the displayed score
Folds this frame's pending points into the on-screen score. The double score prize adds them twice.
add_pending_score B37A LD A,(pending_score) Return at once if no points are pending. Otherwise capture the pending count into C for the score add.
B37D OR A
B37E RET Z
B37F LD C,A
B380 CALL add_points_to_score Add the pending points to the score.
B383 LD A,(double_score) Double score prize active? If so, jump to add the same points again.
B386 OR A
B387 JR NZ,double_score_readd
B389 XOR A No prize: clear the pending points for the next frame and return.
B38A LD (pending_score),A
B38D RET
double_score_readd B38E LD A,(pending_score) Double path: reload the pending count into C, clear the pending points, then fall through into the score add for the second add.
B391 LD C,A
B392 XOR A
B393 LD (pending_score),A
← B351 Draw the score and high-score readouts Map B396 → Add the points to the score and redraw it
Fork me on GitHub