Skip to main content

Module map

Module map 

Source
Expand description

Reader for Blood .MAP files (signature BLM\x1a, versions 6.x and 7.x).

Version 7 maps obfuscate every record with a rolling byte XOR (key, key+1, …). Geometry records use the classic Build v7 layout (sector 40 bytes, wall 32, sprite 44); Blood adds optional β€œextra” records (XSECTOR / XWALL / XSPRITE) stored as packed, little-endian, LSB-first bitfields directly after their owner record.

StructsΒ§

BitReader
Little-endian LSB-first bit reader (matches x86 C bitfield packing).
Cursor πŸ”’
Map
Plane
Sector
Sprite
Wall
XSector
XSprite
XWall

ConstantsΒ§

SECTOR_SIZE
SPRITE_SIZE
WALL_SIZE

FunctionsΒ§

i16_at πŸ”’
i32_at πŸ”’
invalid πŸ”’
map_crypt
Rolling XOR used by v7 maps: byte i is XORed with (key + i) & 0xff.
parse_plane πŸ”’
u16_at πŸ”’