![]() |
Data |
| Prev: 5B80 | Up: Map | Next: 5BA5 |
|
The landscape renderer (draw_landscape) draws the four map cells (pages) the view straddles in turn -- the view's own page at the map position (ground_cell = 0), the one below it (1), the one to its right (2) and the one below and right (3) -- and keeps a list of collision boxes, 37 bytes, for each: loader_entry (written over the loader), ground_cell_bottom_left, ground_cell_top_right and ground_cell_bottom_right. find_page_boxes finds the list for a map column and row by comparing them with the view's own.
The list: +0 the number of pieces the page's tile has (zero for a page with none, and for all four while the map position's row is 0, 1 or 2, when scroll_landscape clears them and does not call draw_landscape at all); then, only while record_ground is set, five bytes for each piece as it was drawn, written through the pointer at collision_object by draw_landscape: +0 its x, +1 its y, +2 and +3 its extent (worked out from the piece's direction and its number of steps), +4 a byte looked up by the direction. These are the ground's collision boxes, read by leave_slope and place_collision_box (through find_page_boxes and move_across). The meaning of +2 to +4 in detail is for those routines.
|
||||
| ground_cell_top_left_rest | 5B99 | DEFB $00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00,$00 | Bytes 25-36 of the list (its first 25 are at loader_entry) | |
| Prev: 5B80 | Up: Map | Next: 5BA5 |