; tiles are 2x2 areas
; this simply defines the first tile
; in the set
-#define TILE_FLOOR_1 14
+#define TFLOOR1 0x41
; maps are collections of rooms
; there is no scrolling
; rooms may have 4 regular exits and 1 secret exit
+
+
+ ; draws the entire room to the tilemap
+ ; disable rendering before drawing a room!
+ ; inputs:
+ ; curr_toom: pointer to current room
room_draw:
+ ; load current room ptr
+ ld a, [curr_room+1]
+ ld d, a
+ ld a, [curr_room]
+ ld e, a
+ ld hl, SCRN0
+
+@copy_meta_tile:
+ ld a, [de]
+ ld [hl+], a
+ inc de
+
+
ret
; base room
; this can be copied and modified
; by the map gen
base_room:
-
+.db TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1
+.db TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1
+.db TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1
+.db TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1
+.db TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1
+.db TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1
+.db TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1
+.db TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1
+.db TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1, TFLOOR1