source-engine
source-engine copied to clipboard
[Guide] How to succesfully compile and run on windows.
This guide will tell you how to prepare, compile and run build game.
- Install visual studio 2017 or 2022 with vs 2017 build tools, git or github desktop and python 3
- Cloning a. clone with git: git clone https://github.com/nillerusr/source-engine.git --recursive b. clone with github desktop.
- Go into command prompt and run these commands: waf.bat configure -T release --prefix=hl2 --build-games=hl2 --disable-warns waf.bat build -p -v waf.bat install
- now you have a directory called "hl2" with all binaries
- copy hl2 and platform from your hl2 install (steam) (skip overwriting files) (if you build any other game also copy it's folder)
- double click on hl2_launcher.exe
OTHER IMPORTANT THINGS
- want voice chat? add --enable-opus to configure
- change build game? change --prefix and --build-games in configure hl1 = Half-Life 1: Source hl2 = Half-Life 2 // Default - This will be selected if you don't specify a game episodic = Half-Life 2 Episode 1 ep2 = Half-Life 2 Episode 2 // Do not build for ep2, use episodic instead. hl2mp = Half-Life 2: Deathmatch dod = Day of Defeat cstrike = Counter-Strike: Source portal = Portal
- black screen when starting a game? copy shaders from half-life 2 (#350)
- need 32 bit build? add --32-bits to configure
- need debug? change -T release to -T debug