Game Crash on Particle Spawn in Unlit map

Whenever a particle effect is spawned in a map with no lighting built, the game will crash - but only if the game is launched from Hammer or otherwise skips loading of background maps.

I was working in Hammer today on a scripted scene that includes a ragdoll, and I noticed that every time the ragdoll hit the ground, the game would crash. I thought this was probably due to the blood particles in some way, so I did further testing with a gun before the sequence was triggered - and the game crashed again when I fired.

After some further testing, I’ve managed to get the symptoms down to the following conditions for reproduction:

  • Particles are being spawned in the map through code (or info_particle_system).
  • The map has no lighting built.
  • No maps with lighting have been loaded by the game before loading the map with no lighting built.

The computer I’ve encountered the bug on (so far) is running Windows 8.1 64-bit. I’ve had no issues with Black Mesa on this machine before, and I’m running the latest build, updated today.

This is technically not a game-breaking bug, but it’s going to slow down map development if everyone has to build (even fast) lighting every time they want to test things just in the event a particle effect will spawn.

Founded in 2004, Leakfree.org became one of the first online communities dedicated to Valve’s Source engine development. It is more famously known for the formation of Black Mesa: Source under the 'Leakfree Modification Team' handle in September 2004.