rules_doom provides Bazel rules for launching Doom engines, packaging IWADs
and PWADs, and generating PWADs from supported source formats.
load("@rules_doom//doom:defs.bzl", "doom_launch")
doom_launch(
name = "play",
)bazel run //:play
bazel run --@rules_doom//config/engine=uzdoom //:play
bazel run --@rules_doom//config/iwad=freedoom1 //:playdoom_launch(...) defaults to //doom/engine and //doom/wads:iwad.
The selected targets are controlled by:
--@rules_doom//config/engine=uzdoom
--@rules_doom//config/engine=crispy
--@rules_doom//config/engine=ascii
--@rules_doom//config/iwad=freedoom1
--@rules_doom//config/iwad=freedoom2load("@rules_doom//doom:defs.bzl", "doom_launch")
doom_launch(
name = "play_mod",
pwads = ["//path/to:my_mod"]
)Commercial IWADs such as DOOM2.WAD are not bundled. If you legally own one,
point Bazel at your local file from your root MODULE.bazel:
doom_local_iwad_repository = use_repo_rule(
"@rules_doom//doom:repositories.bzl",
"doom_local_iwad_repository",
)
doom_local_iwad_repository(
name = "doom2_iwad",
path = "/absolute/path/to/DOOM2.WAD",
map_namespace_style = "mapxx",
)Then pass iwad = "@doom2_iwad//:iwad" to doom_launch(...).
Generated PWAD helpers use the bundled tool repositories directly:
doom_udmf_pwad(...)builds a playable PWAD from UDMF text.doom_wadc_pwad(...)builds a playable PWAD from WadC source.
The repository includes a generated WadC example that builds an upstream WadC
source file from jmtd/wadc into a PWAD and
runs it through the normal doom_launch(...) path:
bazel run //examples/wadc:entrywayrules_doom can run doom in the bazel terminal
doom-ascii inspired by
snazel.
bazel fetch --force --repo=@doom_terminalrules_doom itself is Apache-2.0. Downloaded engines, tools, IWADs, and PWADs
keep their own licenses. Commercial IWADs are not bundled.