The DOS Engine Architecture

The DOS Engine Architecture

The Wolfenstein 3D source release is organized as a compact DOS game layered over a set of reusable id Software support libraries. Files prefixed ID_ provide memory, caching, input, page management, sound, and video services, while the WL_ files contain the Wolfenstein-specific game, actor, map, and renderer logic. This distinction is visible immediately in WOLFSRC.

Wolf3D game code layered over id support libraries

ID_MM supplies memory management, ID_CA handles cached resources, ID_PM manages paged data, ID_IN reads input, ID_SD controls sound, and ID_VL or ID_VH operate the VGA display. Above those services, WL_MAIN.C, WL_GAME.C, WL_PLAY.C, WL_DRAW.C, and the actor files define the particular game.

This division is important when tracing a feature. A wall column is computed by Wolfenstein’s renderer but presented through the video layer; a key press is translated by the generic input layer but interpreted by the play loop; and a resource cache miss belongs to the cache manager even when the caller is a game-specific system. The code is old, but the separation of platform services from game rules is already explicit.