Stranger Beings - AI Dev Blog

    This site uses cookies. By continuing to browse this site, you are agreeing to our use of cookies. More details

    • Stranger Beings - AI Dev Blog

      Hello fellow research associates,

      With the warmth of summer drawing to an end I thought it would be the perfect time to delve into the mysterious realm of Xen through AI programming.

      This summer I have been working near round the clock to get a lot of our NPCs into a much more solid state than they were just a little over a few months ago. A while back (if you consider a while to be 4 years) we had released a dev blog about the progress our team was making in getting all of the familiar faces in the original games up and running. To cut the story short – unfortunately a lot of the AI broke when moving to a newer build of the Source Engine, giving me the opportunity to not only get them back to a working state, but make the creatures that roam the halls more lifelike than ever.

      Deviating from the Half-Life games for a moment, AI programming in video games isn’t really AI programming in the true definition of the word. For video games, most AI run off of what are known as state machines, basic checking of conditions to determine what to do. While some AI can be basic, such as turrets (if I see the enemy, shoot at the enemy), to make a truly thriving and believable ecosystem, you have to go a little further than that.

      Do alien dogs dream of subatomic sheep?

      To touch on one of the AI’s presented all those years ago, the Houndeye, besides having improved visual effects and feedback, now acts more like how you may expect a wild pack animal to behave. The Houndeyes are now much more alert to their surroundings, patrolling the nearby landscape, getting up on the hind leg to look about, and snoozing when they determine the area to be safe. When operating in a squad, the leader will be the most active in patrolling the surroundings while it’s pack members are more inclined to doze off in the sun. The Houndeye is also much more expressive now, having a few unique limping and flinching behaviors when taking damage based on their health and the direction they were facing compared to where the damage came from.

      Not necessarily the fish you want to be sleeping with.

      Your good friend (or nightmare) the Ichthyosuar was another monster that I had fun working. The AI for our fishy friend existed in a relatively non-usable form from Half-Life 2. It appears a Valve programmer had started work on their AI but then gotten pulled to another task, or the Ichthyosaur was just deemed not necessary anymore. I had a couple ideas I wanted to try with the Ichthyosaur in order to get a realistic, yet threatening underwater monster for players to have to contend with. I played around with the idea of having the monster act like an alligator, latching onto its prey’s leg and dragging them to the depths of their lair in an effort to drown and then consume their prey. This proved a tad unfair though as the player would already be highly disoriented from the murky environments the Ichthyosaur resides within naturally. Being dragged around at high speeds didn’t make this experience any more enjoyable.

      And there’s the kicker with AI programming. You could make everything hyper realistic – but is the player still having fun? If not, then chances are you may have gone a tad too far or just the wrong direction all together. The next iteration of the Ichthyosaur has gotten the results desired – the fear of the unknown. As Ichthyosaur’s love to dwell in grungy, dark bodies of water you can never be sure from which angle they will attack, or if there is even one swimming along with you out of sight. Studying the feeding patterns of piranha’s, I modeled their behavior to resemble these carnivores fish here on Earth. The Ichthyosaurs will team up if multiple reside in the same pool of water to take a chomp out of the player from all angles, before swimming quickly off into the murk, out of sight. After a slightly random period of time they will return in a flash for another bite before all that’s left of the intruder is bits of fish food.

      Maybe not knowing what lurked in the dark was for the best...

      Deviating from Xen, we will look at the Voltigore. Being in charge of Foxtrot Uniform I have had a great time designing their AI and ecosystem to create a realistic environment that just was not feasible back when Opposing Forces came out. When playing through this segment, those who choose not to run in guns blazing will notice that the Voltigore adults maintain patrol cycles to guard the nurseries where their young live (and, unfortunately, near where you need to pass through). Being creatures that live naturally in the dark, evidenced from where their nests are found, alongside being carnivores, their eyesight primarily provides them with frontal vision that isn’t the best in the world. Players who realize this and take advantage of their biological weaknesses will have an easier time trekking through the hives alive. Once seen though the entire Voltigore network will light up faster than a Christmas Tree. Hurting their children may yield similar results…

      While this has been just a glimpse into the thought that goes into making the characters of Black Mesa create a realistic, environmentally sound world, hopefully you’ll be able to see the full impact this attention to detail has when you get a chance to explore the different environments of our games yourself.

      Until next time,

      Chris “Tmast” Onorati
    • "...Studying the feeding patterns of piranha’s, I modeled their behavior to resemble these carnivores fish here on Earth..."

      "...Creatures that live naturally in the dark, evidenced from where their nests are found, alongside being carnivores, their eyesight primarily provides them with [poor] frontal vision..."

      I'm probably a broken record at this point, but the amount of dedication from every member of this team is astonishing. It might be a slanted comparison due to the capabilities of the time, but I don't think the original teams that worked on Opposing Force, Blue Shift, or even Half-Life 1 and its sequels took even half the time and specificity in their logical and narrative efforts as you guys do.
    • Tmast98 wrote:

      You could make everything hyper realistic – but is the player still having fun?

      I think its a bad idea toning down realism just for "gameplay reasons" because thats what takes away fun, if you realize realism was intentionally taken away just to make it "fair". It then feels like "something was taken away" kind of.
      One example of this is the HE nades in CS:GO - they were nerfed so much so they are no longer grenades (they could best be described as new year fireworks) basically just to make it "balanced", but in real life grenades kill, not just a little itch.

      I think its better to make it as hyper realistic as possible, but instead tweak other numbers where you don't "notice it" (damage inflicted, damage taken etc) to not make it "too unfair". For example, player is propably not going to notice that the fish is a bit "too easy" to kill, so better adjusting those properties instead.

      Or tweak the dragging functionality so when the fish tries to drag you down, you can still counteract it to a certain degree. There is lots of tweaking to do without taking away the hyper realism.

      Post was edited 2 times, last by sebastian ().

    • It's tough to really make this Call without having seen the original "realistic" product.

      A good comparison would be, what if, in order to make fire fights more realistic, they added accurate recoil, a pain mechanic that would cause camera shake and blurry vision, and randomly timed gun jams? They may be interesting novelties at first, but they would become supremely irritating and rage-inducing in the long term, slowing down the story pace and ramping up your need for quick saves.

      I'm sure the dev team gave the "realistic" version ample time and testing, and ultimately made the right call.

    © 2019 Tripmine Studios. Valve, Steam, Gearbox, Half-Life Trademarks of Valve.