![]() |
Routines |
| Prev: D15D | Up: Map | Next: D18E |
|
Used by the routines at DrawView and FindObjectsInCell.
Converts the column and the row of a cell between the map and the view, which are the same unless the view is rotated, when both are turned around.
|
||||||||||||||||
| ConvertCell | D17D | LD A,($BBBA) | Return if the view is not turned round. | |||||||||||||
| D180 | AND $01 | |||||||||||||||
| D182 | RET Z | |||||||||||||||
| D183 | LD A,L | Turn the column round by subtracting it from 1F. | ||||||||||||||
| D184 | CPL | |||||||||||||||
| D185 | AND $1F | |||||||||||||||
| D187 | LD L,A | |||||||||||||||
| D188 | LD A,H | Turn the row round by subtracting it from 1F. | ||||||||||||||
| D189 | CPL | |||||||||||||||
| D18A | AND $1F | |||||||||||||||
| D18C | LD H,A | |||||||||||||||
| D18D | RET | Return. | ||||||||||||||
|
View the equivalent code in;
|
||||||||||||||||
| Prev: D15D | Up: Map | Next: D18E |