Prev: 41550 Up: Map Next: 41633
41617: Script routine: (64) Set random (1 to 10) number of iterations in following loop script instruction
Used by the routine at 48096.
41617 LD A,10 Load A with a random number, 1-10...
41619 CALL 54222 ...
41622 INC A ...
41623 PUSH HL Store HL (current position in script data)
41624 LD BC,4 Advance HL by four bytes...
41627 ADD HL,BC ...to number of iterations in next (loop) instruction...
41628 LD (HL),A ...and set number of iterations to number generated
41629 POP HL Restore HL (current position in script data)
41630 JP 48096 Advance HL to next script instruction and execute
Prev: 41550 Up: Map Next: 41633