Routines |
Prev: 62516 | Up: Map | Next: 62648 |
Used by the routine at ProcessMonsters.
|
||||
62544 | LD B,A | B=A. | ||
62545 | INC HL | Increment HL by one. | ||
62546 | LD C,(HL) | C=*HL. | ||
62547 | INC HL | Increment HL by one. | ||
62548 | LD A,(HL) | A=*HL. | ||
62549 | RRCA | Rotate A right one position, setting the carry flag if bit 0 was set. | ||
62550 | RET NC | Return if the carry flag is not set. | ||
62551 | INC HL | Increment HL by one. | ||
62552 | LD A,(HL) | A=*HL. | ||
62553 | RRCA | Rotate A left one position, setting the carry flag if bit 0 was set. | ||
62554 | RET C | Return if the carry flag is set. | ||
62555 | LD (53800),BC | Write BC to *53800. | ||
62559 | LD H,0 | H=0. | ||
62561 | LD L,B | L=B. | ||
62562 | LD D,H | D=H. | ||
62563 | LD E,C | E=C. | ||
62564 | ADD HL,HL | HL*=32+DE. | ||
62565 | ADD HL,HL | |||
62566 | ADD HL,HL | |||
62567 | ADD HL,HL | |||
62568 | ADD HL,HL | |||
62569 | ADD HL,DE | |||
62570 | LD A,1 | A=1. | ||
62572 | LD (54267),A | Write A to *54267. | ||
62575 | LD (53802),HL | Write HL to *53802. | ||
This entry point is used by the routines at Handler_Eating and Handler_EatFood.
|
||||
62578 | LD DE,319 | DE=319. | ||
62581 | CALL 57551 | Call 57551. | ||
62584 | LD A,(54268) | A=*54268. | ||
62587 | RRCA | Rotate A right one position, setting the carry flag if bit 0 was set. | ||
62588 | JR C,62592 | Jump to 62592 if the carry flag is set. | ||
62590 | JR Z,62600 | Jump to 62600 if A is zero. | ||
62592 | LD BC,0 | BC=0000. | ||
62595 | LD E,1 | E=1. | ||
62597 | CALL 62787 | Call 62787. | ||
62600 | LD A,(53781) | A=*53781. | ||
62603 | CP 77 | Jump to 62694 if A is lower than 77. | ||
62605 | JR C,62694 | |||
62607 | SUB 76 | A-=76. | ||
62609 | AND %00000011 | Keep only bits 0-1. | ||
62611 | CP 1 | Jump to 62694 if A is not equal to 1. | ||
62613 | JR NZ,62694 | |||
62615 | LD A,1 | Write 1 to *54268. | ||
62617 | LD (54268),A | |||
62620 | LD A,(53781) | A=*53781. | ||
62623 | SUB 77 | A-=77. | ||
62625 | SRL A | Shift A right twice. | ||
62627 | SRL A | |||
62629 | CP 8 | Jump to Handler_Eating if A is lower than 8. | ||
62631 | JR C,Handler_Eating | |||
62633 | AND %00000011 | Keep only bits 0-1. | ||
62635 | INC A | Increment A by one. | ||
62636 | ADD A,A | A+=A. | ||
62637 | LD D,A | D=A. | ||
62638 | LD E,3 | E=3. | ||
62640 | LD A,(57157) | A=*Temp_MonsterID. | ||
62643 | CALL Handler_AddPoints | Call Handler_AddPoints. | ||
62646 | JR Handler_EatFood_SetState | Jump to Handler_EatFood_SetState. |
Prev: 62516 | Up: Map | Next: 62648 |