Robert Briscoe | Artist | Developer
WW.jpg

Archives

An archive of old devblog posts from various projects over the years

Prototyping and code

Originally Posted July 16, 2008

When the idea for this project first bubbled to the surface of my imagination, I knew I would need to make some essential modifications to the Source Engine before I could even contemplate the idea. So before I started making any kind of art or maps for it I needed to explore the optimisation possiblilities within the source engine, for this I have the help of two very talented coders: Jacob Hendricks and R_Yell or Rebel_Yell as he’s known.

AI

My biggest hurdle was to have a persistent world populated by potentially hundreds of zombie NPCs. Initial tests on an unmodified Source Engine were pretty uninspiring; having just over 25 NPCs in the world at once was a huge drain on fps due to the nature of how Source’s own AI works, and on top of that I wanted my map to be set in a large open environment.

Optimising:

LODing and Culling
The main problem was that Sources default AI LODing isn’t aggressive enough to suit my needs. I really needed a system of setting how docile/intelligent the NPCs are depending on the distance to the player; coupled with a way to cleanly ‘cull’ (freeze activity and stop rendering) them from the world at another distance, so that they don’t take up vast amounts of CPU when far away or not seen.

Efficient environment
In the map I’m designing I have set up certain limitations on my environment to compliment this such as a set draw distance which will be hidden by a dark environment and thick fog. This way whenever an NPC is beyond the draw distance I can set it to be immediately culled, whereas at the moment Source tends to have a wide buffer zone before it culls out the AI completely (which I’m pretty sure relies on visleafs, something I can’t rely on too heavily in such an open map).

Adaptive AI Efficiency
Another optimisation idea is to have some kind of system which counts the number of NPCs that are visible at one time and if it reaches a certain limit, it will change the efficiency level of the NPCs (i.e. make the think time slower or reduce animation latency) There are already efficiency levels to the AI, so its just a case of how to activate them based on these conditions.

Zombie Vision
Finally with the dark environment and fog I could also make the zombies’ vision pretty poor, so that basically if you move too far away from them and then are shrouded in fog, they will loose sight and simply sleep (finish actions and just wait in an idle state until woken). This could potentially save even more CPU for the ‘Shambler’ class zombie of which there will be many in the world. It will also allow you the opportunity to sneak around hoards of Shamblers without being spotted, as well as adding a bit more strategy and stealth to the game play.

Essential Features

Although the AI optimisation is the main concern for the project to work, there are also some other small, but very important features I would need to be implemented, which will hopefully not be too much work:

Incremental Zombie HealthTo add a bit more of a difficulty curve to the game play, and prevent players from straying from the main objectives and simply gunning zombies non-stop (as fun as that may be in the short-term) I want the zombies to become slightly more resistant with each kill you make. For example, for each zombie you kill, the next will have two more health points. This would build until it’s no longer a case of mowing down the undead without a care, they will become so resistant that it could take up you entire ammo supply before they finally become worm food, forcing the player to change and adapt using new strategies and tactics to complete their objectives.

No Head crabs!
This goes without saying really if I’m to detach my mod from the hl2 universe. Is very easy to do though, I’ve actually already managed to do it once on my own (even though I’d never used VS before! Heh) so this is not such a big issue.

Dream Features

These are just some ideas that are totally not essential for me to make the mod but would make very nice additions!

Headshots
To be consistent with the zombie universe built up by my idol George Romero and with many other zombie franchises people have grown to know over the years, I would love to see insta-kill headshots implemented into the game. I’m not 100% sure how it would work for the game play, but is definitely something I’d love to try out. Of course if this were to be implemented it would mean that zombies would be invulnerable on, or would have to take massive damage to, their other bodily regions before eating the dirt.

Navigation Aid:
I think even implementing a simple overview map system similar to Counter Strike would be good enough. This is mainly so that the players have less of a hard time getting lost and can have clear marked out objectives without aimlessly looking for something. Something so they can simply press a key which brings up a map which shows them where they are (no HUD minimap though as it would kill immersion)

Regenerative Health ala Gears of War (see SMOD video below for good visual example)
Very arcade-y at first glance, but I think it will fit better with the game play than having health packs lying around in this kind of environment. This would mean I could get rid of the health meter, instead only having a subtle visual aid to indicate how badly hurt you are (e.g. screen fades to red). Of course this is only a very minor detail and not totally essential to game play but is something that could possibly improve immersion while removing the frustration of having to side-track running back and forth to find health kits.

Iron sights
Again to help with immersion, and to also make the players more tactical and strategic with the weapons and ammo, for this I’d also love to remove the HUD aiming reticule completely.

And finally…

Custom NPC similar to SMOD
This is of course a total pipe dream but I really love the AI (even if really stupid) in SMOD’s modified zombies:

 http://www.youtube.com/watch?v=p9cYpVYMwc4

It seems like a pretty simple AI modification to an NPC citizen or something, where they are idle until they see or hear the player then just run straight at them causing damage if they come into close contact with the player. They also seem to run to random path nodes whilst searching for the player also which also crude looks pretty convincing!
But anyway totally not essential….but nice! 😛

Good night!

Rob