1986 · Domark

Friday the 13th: maps

This minisite was curated by air, unorig.

All 44 rooms of Crystal Lake camp, each drawn in the page by the game's own drawing routine, laid out as the game joins them, with the doors between them and where everyone starts a round.

01 · Room viewer

Any room, drawn the way the game draws it

Pick a room in any of the four maps below, or step through them here. The labels on each map say where a door leads, which rooms start a tune of their own, and where you and the ten others begin a round.

02 · The camp

Outdoors: 24 rooms, 4 across and 6 down

The woods and the lake around the cabins. Walk off any side of a room and the next one is drawn; the edge of the map stops you. Three rooms have a door into a building.

03 · The lodge

The lodge: 12 rooms, 3 across and 4 down

The largest building, the brick one with the red roof in room 17 outdoors. The game gives its buildings no names, so this page names them after how they look from outside.

04 · The church

The church: 4 rooms, where every round starts

Entered from room 11 outdoors. The player starts each round in room 38, the church with its benches and organ.

05 · The barn

The barn: 4 rooms

The wooden barn with the thatched roof, entered from room 9 outdoors.

06 · A room, rebuilt

One room drawn by the game's own routine

Rooms are built from tiles of cells laid over a background, by draw_room. The page runs that routine, unchanged, on the game's bytes.

The game's picture of room 39

Room 39, beside a screenshot of the same room in play. The drawing leaves out the two people standing there: people are sprites, which draw_room does not draw.

Each room is 8 tiles across and 4 down, 32 bytes at $0C00 plus 32 times the room's number. A tile is 4 by 4 cells, and a cell is 8 by 8 multicolour pixels. The cells' see-through pixels let the background show: plain grey outdoors, and indoors one perspective picture of walls and floor that every building room shares, recoloured for each room from two bytes at room_colours.

The room is also the collision map. Its 32 tiles are copied to room_map, and tile_kind sorts the tile under each foot into open, solid, or climbable. Outdoors, walking off a side of the screen moves you one room across the 4 by 6 grid; in a building, the floor narrows with depth, and you leave through the doorways in the walls.

07 · How a room is stored

32 tiles a room, 16 cells a tile

Each room is 32 bytes at $0C00 plus 32 times its number: 8 tile numbers across and 4 down. A tile is 32 bytes at $8000 plus 32 times its number, 4 cells across and 4 down, each a two-byte number of an 8-byte multicolour cell at $1180. draw_room lays the tiles over a background: a plain grey field outdoors, and in a building the same perspective picture of walls and floor for every room (a 16 by 32 map of patterns at $0400), recoloured from two bytes per room at $AA5E. A cell's %00 pixel pairs let that background show through, so the furniture stands on the floor.

In a building, a room on the building's outer edge gets its doorway on that side painted over by draw_area_edges: the side walls' doors on the left and right edges, and a block of the back wall on the first row.