Prev: B745 Up: Map Next: B766
B755: Increment café tab (var_cafe_tab) by B
Reads var_cafe_tab (two ASCII digit bytes) into HL. Increments L (units digit). If L wraps past '9' ($3A), calls cafe_tab_carry (carry into tens digit). Loops B times and writes the result back.
Called from cafe_encounter each time the player confirms a café purchase.
Input
B Number of times to increment café tab
increment_cafe_tab B755 LD HL,($C338)
B758 LD A,L
B759 INC A
B75A CP $3A
B75C CALL Z,cafe_tab_carry
B75F LD L,A
B760 DJNZ increment_cafe_tab
B762 LD ($C338),HL
B765 RET
Prev: B745 Up: Map Next: B766