Prev: 50170 Up: Map Next: 50194
50177: Check Active Scenic Events
Input
HL Pointer to scenic data
A
Output
F The Z flag is set then there are no matching scenic events
CheckActiveScenicEvents 50177 JR ActiveScenicEvents_CheckNext Jump to ActiveScenicEvents_CheckNext.
ActiveScenicEvents_Loop 50179 INC HL Move to the next event ID.
ActiveScenicEvents_CheckNext 50180 LD A,(HL) Jump to NoActiveScenicEvents if *HL is equal to 255.
50181 CP 255
50183 JR Z,NoActiveScenicEvents
50185 CALL ValidateItemPresent Call ValidateItemPresent.
50188 JR NZ,ActiveScenicEvents_Loop Jump to ActiveScenicEvents_Loop if the Z flag is not set.
50190 LD A,(HL) A=*HL.
50191 RET Return.
NoActiveScenicEvents 50192 AND A Set Z flag.
50193 RET Return.
Prev: 50170 Up: Map Next: 50194