# Quake 2 on Ubuntu 22.04 ```{note} You **cannot** as of 2023-10-31 run Quake 2 Enhanced on Linux. https://www.reddit.com/r/linux_gaming/comments/15o4pth/comment/jw4b4da/ ``` ## Cheatsheet ``` ls ~/games/q2 # install data ls ~/.yq2/ # configs ``` ## Install and Configure Yamagi Quake 2 Install the `quake2-engine` package without the `game-data-packager` [^gdp]. ``` sudo apt-get install --no-install-recommends \ libopenal1 quake2-engine ``` ## Buy, download, extract [Buy the game][buy], download the `Quake II (Original)` installer to `~/Downloads/q2/` and extract the files using {ref}`innoextract`: ``` cd ~/Downloads/q2/ innoextract setup_quake2_quad_damage_2*.exe rm -r tmp/ # gog installer files install -d ~/games/ mv app ~/games/q2 ``` [buy]: https://www.gog.com/en/game/quake_ii_quad_damage ## Install fixed "Ground Zero" Extension (rogue) The elevator in rogue was missing. :D ``` git clone https://github.com/yquake2/rogue.git /tmp/rogue/ cd /tmp/rogue/ make -j8 install -d ~/games/q2/rogue/ cp release/game.so ~/games/q2/rogue/ ``` ## Create a launcher and Play ``` cat <<'EOF' > ~/.bin/q2 /usr/lib/quake2/quake2-engine -datadir ~/games/q2/ "$@" EOF chmod +x ~/.bin/q2 ``` [^gdp]: The `game-data-packager` introduces indirections and installs stuff at `/usr/share/games/`. I want to keep it simple: Get binary (engine), point it to data dir, play! ## Configuration ``` install -d ~/.yq2/baseq2/ cd ~/.yq2/baseq2/ git init . git add . git commit -m initial cat <<'EOF' > ~/.yq2/baseq2/autoexec.cfg exec bindings.cfg EOF cat <<'EOF' > bindings.cfg bind e "use grenades" EOF ``` See also - https://steamcommunity.com/sharedfiles/filedetails/?id=675678575 - https://steamcommunity.com/app/2320/discussions/0/1734343065619797360/ ## Notes - press Alt+Enter to toggle fullscreen ## vkquake2 https://github.com/kondrak/vkQuake2 ``` sudo apt install make gcc g++ mesa-common-dev libglu1-mesa-dev libxxf86dga-dev libxxf86vm-dev libasound2-dev libx11-dev libxcb1-dev wget -qO- https://packages.lunarg.com/lunarg-signing-key-pub.asc | sudo tee /etc/apt/trusted.gpg.d/lunarg.asc sudo wget -qO /etc/apt/sources.list.d/lunarg-vulkan-1.3.268-jammy.list https://packages.lunarg.com/vulkan/1.3.268/lunarg-vulkan-1.3.268-jammy.list sudo apt update sudo apt install vulkan-sdk vulkaninfo | rg -A2 'Presentable Surfaces:' cd ~/github/ g clone https://github.com/kondrak/vkQuake2.git cd vkQuake2/ cd linux/ make -j 8 release ```