Routines |
Prev: DD6C | Up: Map | Next: DD97 |
Used by the routine at Handler_EatFood.
|
||||||||||
Handler_IncreaseEnergy | DD89 | ADD A,(IY+$0C) | Add the energy value to the monsters current energy level (*IY+0C). | |||||||
DD8C | LD (IY+$0C),A | |||||||||
Ensure the maximum value for monster energy is not breached.
|
||||||||||
DD8F | CP $41 | Return if the monsters energy is lower than 41. | ||||||||
DD91 | RET C | |||||||||
DD92 | LD (IY+$0C),$40 | Else write 40 to the monsters energy (*IY+0C) to keep it within the acceptable range. | ||||||||
DD96 | RET | Return. |
Prev: DD6C | Up: Map | Next: DD97 |