as3.jpg (6675 bytes)

··· news ··· documentation ··· files ···  links ···

 
Description of AlphaSkaarj 0.1 (alpha)
The only documentation available right now is the README file, included in the distribution. Here's an excerpt from that README describing the project:

AlphaSkaarj is a new type of a monster for Unreal (a first-person shooter from Epic Games), a monster that is designed to behave more believably than most current creatures.

Unlike virtually all monsters in first-person shooters, AlphaSkaarj does not use a large finite state machine for behavior control. Instead, I have used methods from behavior-based robotics to implement actions as a set of parallel behaviors, all of which are always active, and one or more of which actually drive the robot at any given time. This programming style, and the close coupling of perception and action, are very much inspired by studies of animal behavior.

Yes, this monster does have perception. Simple as it is, it continually senses the environment around it to find obstacles, and therefore it can navigate around a map without using navigation points. It also actively detects good occlusion points (where it can hide from the player), also using continuous perception.

Action selection is done via a network of simple behaviors (such as 'shoot', 'find cover', 'run for cover', etc.) which are often grouped to form more complex ones. Each behavior is a rule that evaluates into a vector pointing where the behavior wants the creature to go, any special actions that have to be performed (such as shooting), and an activation level that corresponds to how important this behavior is. All behaviors are always active, but only those with highest activation levels will have effect on the creature. So, for example, when the monster notices the player for the first time, its 'run for cover' behavior will point it away from the player and toward the occlusion, and have a very high activation level (so that other behaviors won't be able to override it). On the other hand, once the monster hides from the player, the activation level on 'run for cover' will drop enough for other behaviors (such as 'jump out') to take charge of the monster's action.

This network of behaviors was written in a Generic Robot Language developed in our Autonomous Mobile Robotics Group, and compiled straight into UnrealScript. The big block of compiled code you see in the middle of the source for this monster is the output from the compiler. And like most compiled code, it's completely unreadable. :) The compilation means, however, that execution of behaviors is *really* fast. (In fact, the vast majority of CPU cycles is spent on perception, not behavior control.)



Aside from being a guinea pig for implementing behavior-based action control, this monster also presents a different approach to gameplay - so let's take a look at what it actually does.

Something which I found annoying about game creatures is that they are entirely too happy to engage in suicide attacks - that is, run towards the player and hack away until they kill the player, or die trying. But in real life, humans don't fight like that. Unlike in games, in real life people do all they can to *avoid* enemy fire - by running for cover, for example.

AlphaSkaarj is an attempt at bringing similar behavior to first-person shooters. Instead of just attacking the player, the monster will immediately try to find cover - i.e., an area that it can see but which is hidden from the player's view. After it finds cover it will try to stay in hiding for most of the time, occasionally jumping out to shoot at the player. If it jumps out and doesn't see the player, it will go in the direction where he was seen last.

(BTW: I know, I know, this goes against the first-person shooter play style of continuously running around and shooting at everything that moves. That is deliberate. AlphaSkaarj is not a bot one could play against to practice for Deathmatch. It's a creature that will not attack until it sees you, and will not pursue you too vigorously. It's a good monster for placing in a custom-built level, but it shouldn't be mistaken for a bot.)



Copyright 1999 Robert Zubek. Email me with questions and comments!