![]() |
Routines |
| Prev: C763 | Up: Map | Next: C821 |
|
Used by the routines at TestLowBitsOfCharacter and TestLowBitsOfGraphics.
Keeps bits 0-3 and tests the seventh and eighth markers.
|
||||
| TestSeventhMarker | C7A6 | AND $0F | Jump back to TestLowBitsOfCharacter_ReportMatch if the low nibble is command 07. | |
| C7A8 | CP $07 | |||
| C7AA | JP Z,TestLowBitsOfCharacter_ReportMatch | |||
| C7AD | CP $08 | Go to TestSeventhMarker_CommandNine when the command is not 08. | ||
| C7AF | JR NZ,TestSeventhMarker_CommandNine | |||
| C7B1 | LD A,C | Take the count, then call CheckObjectLocationMatch to test object location match. | ||
| C7B2 | CALL CheckObjectLocationMatch | |||
| TestSeventhMarker_0 | C7B5 | JP Z,TestLowBitsOfCharacter_GiveUp | Go to TestLowBitsOfCharacter_GiveUp if the object is not in this location. | |
| C7B8 | JP TestLowBitsOfCharacter_ReportMatch | Jump back to TestLowBitsOfCharacter_ReportMatch to return non-zero. | ||
|
For command 9, checks the low count and gives up when that check fails.
|
||||
| TestSeventhMarker_CommandNine | C7BB | CP $09 | Jump ahead to TestSeventhMarker_CommandTen if the command is not 09. | |
| C7BD | JR NZ,TestSeventhMarker_CommandTen | |||
| C7BF | LD A,C | Go to TestLowBitsOfCharacter_GiveUp if the object is not in this location. | ||
| C7C0 | CALL CheckObjectLocationMatch | |||
| C7C3 | JP Z,TestLowBitsOfCharacter_GiveUp | |||
| C7C6 | LD A,C | Go to TestLowBitsOfCharacter_GiveUp if the record's first byte is not 01. | ||
| C7C7 | CALL GetObjectAttribute | |||
| C7CA | JP NZ,TestLowBitsOfCharacter_GiveUp | |||
| C7CD | LD A,C | Go to TestLowBitsOfCharacter_GiveUp if the object has a special description. | ||
| C7CE | CALL TestObjectHasSpecialDescription | |||
| C7D1 | JP NZ,TestLowBitsOfCharacter_GiveUp | |||
| C7D4 | LD B,C | Read the character being processed, then call ProcessObjectAttribute_LookObjectRun to run object attribute. | ||
| C7D5 | LD A,($A036) | |||
| C7D8 | CALL ProcessObjectAttribute_LookObjectRun | |||
| C7DB | JP Z,TestLowBitsOfCharacter_GiveUp | Go to TestLowBitsOfCharacter_GiveUp if the attribute comparison borrows. | ||
| C7DE | LD A,C | Jump back to ReadHighByteSource_0 to run display action. | ||
| C7DF | CALL GetObjectMotherID | |||
| C7E2 | JR ReadHighByteSource_0 | |||
|
For command 10, checks the low count and gives up when that check fails.
|
||||
| TestSeventhMarker_CommandTen | C7E4 | CP $0A | Jump ahead to TestSeventhMarker_CommandEleven if the command is not 0A. | |
| C7E6 | JR NZ,TestSeventhMarker_CommandEleven | |||
| C7E8 | LD A,C | Go to TestLowBitsOfCharacter_GiveUp if the object is not in this location. | ||
| C7E9 | CALL CheckObjectLocationMatch | |||
| C7EC | JP Z,TestLowBitsOfCharacter_GiveUp | |||
| C7EF | LD A,C | Jump to TestLowBitsOfCharacter_GiveUp if CheckCharacterIDRange does not match this character. | ||
| C7F0 | CALL CheckCharacterIDRange | |||
| C7F3 | JP NC,TestLowBitsOfCharacter_GiveUp | |||
| C7F6 | JP TestLowBitsOfCharacter_ReportMatch | Jump back to TestLowBitsOfCharacter_ReportMatch to return non-zero. | ||
|
For command 11, checks the low count and gives up when that check fails.
|
||||
| TestSeventhMarker_CommandEleven | C7F9 | CP $0B | Jump ahead to TestSeventhMarker_CommandTwelve if the command is not 0B. | |
| C7FB | JR NZ,TestSeventhMarker_CommandTwelve | |||
| C7FD | LD A,C | Go to TestLowBitsOfCharacter_GiveUp if the object is not in this location. | ||
| C7FE | CALL CheckObjectLocationMatch | |||
| C801 | JP Z,TestLowBitsOfCharacter_GiveUp | |||
| C804 | LD A,C | Call GetObjectAttribute for the object in C and jump to TestSeventhMarker_0. | ||
| C805 | CALL GetObjectAttribute | |||
| C808 | JR TestSeventhMarker_0 | |||
|
For command 12, follows the object that contains this one.
|
||||
| TestSeventhMarker_CommandTwelve | C80A | CP $0C | Jump ahead to TestSeventhMarker_MatchObjectThenRoom if the command is not 0C. | |
| C80C | JR NZ,TestSeventhMarker_MatchObjectThenRoom | |||
| C80E | LD A,C | Call TestObjectHasSpecialDescription and jump back to TestSeventhMarker_0, which gives up when the special description is clear. | ||
| C80F | CALL TestObjectHasSpecialDescription | |||
| C812 | JR TestSeventhMarker_0 | |||
|
The object is in the room, so follow whatever contains it.
|
||||
| TestSeventhMarker_MatchObjectThenRoom | C814 | LD A,C | Give up on this object when it is not in the room, otherwise follow the object that contains it. | |
| C815 | CALL CheckObjectLocationMatch | |||
| C818 | JP Z,TestLowBitsOfCharacter_GiveUp | |||
| C81B | LD A,C | Call TestObjectHasSpecialDescription and jump back to TestSeventhMarker_0, which gives up when the special description is clear. | ||
| C81C | CALL TestObjectHasSpecialDescription | |||
| C81F | JR TestSeventhMarker_0 | |||
| Prev: C763 | Up: Map | Next: C821 |