Game Development Community

dev|Pro Game Development Curriculum

Tactical AI Kit: Download the Working Demo

by Bryce · 09/30/2008 (5:50 pm) · 28 comments

Hello Community,

Okay, this time the demo doesn't crash :-). Sorry about the extra two weeks because of my negligence to test the demo before hosting...Anyway, play instructions are in the help section on the main menu. May you enjoy yourselves whilst you blow away virtual terrorists.

files.filefront.com/TAIKDemozip/;11939462;/fileinfo.html

Screenshots are included in my previous .plan post

A video (sorry about the bad frame rate, my computer sucks):
Page «Previous 1 2
#1
10/01/2008 (12:05 am)
Looking good bryce... although my AI teamate did shoot me in the face once. But maybe he just didn't like me. :)
#2
10/01/2008 (2:36 am)
I can't wait to give this a try, thanks bryce!

@Tom: I wonder if he was a double agent.
#3
10/01/2008 (5:20 am)
@Tom: Lol, yes, that happens sometimes...they usually do a good job of figuring out when it isn't safe to fire, but yes, it could use improvement.
#4
10/01/2008 (5:58 am)
Bryce, I think a lot of Shooters have an anti-friendly-fire system (though I maintain there is nothing friendly about incoming, regardless of who fired it!), so bullets fire by comrades that accidentally hit teammates don't do damage.

I made a real simple one for my old, TGE AI demo were friendly and enemy bullets had Team properties, if after all the usual LOS checks, a bullet still managed to hit a target that had the same Team number they didn't do any damage. Stops the player getting muzzleswept!

Might not be an idea to give the player this option as sometimes an AI might get trapped in the way and the player will need to shoot him as a last resort just to get past. My player and AI had their own weapon categories.
#5
10/01/2008 (6:41 am)
Wow, that is a great demo, the ai really didnt like me though, i ran for cover and the terrorists took me out almost every time. This would be a great pack to bundle up with some documentation. And maybe some varients. like a sniper ai. toss this in with a ai that knows when its out of ammo and can swap to a secondary attack, and were talking a huge FPS tactical AI kit that we as a community are in desperate need of.

Great would be a understatement. Do you have any other plans for AI? This is a huge start.
#6
10/01/2008 (10:20 am)
This looks awesome, I'll have to check it out!
#7
10/01/2008 (11:47 am)
Good fun, and well done Bryce!

Just like any good demo, it's all there in the rough. And it's rock hard!

My only real gripe would be the AI teammates stuck too close and were too bunched up when just following the player. Sometimes I'd stick my head round a corner, come under, try and move back but a gaggle of 3 friendlies would stop me. Oddly enough this is the same complaint I had with the allied AI in Half-Life2. So consider yourself in good company!
[big_thumbs_up]
#8
10/01/2008 (2:05 pm)
Thanks for the comments!

@Edward: I did make some different variants; My AI code uses just about the same structure as Killer Kork does. A ScriptObject that defines the behavior and state machine and everything is assigned to the AI Player and thinks every 1/2 second. To add a different behavior, just add another ScriptObject definition. I had four different types in this demo--Marine Rifleman, OpFor Rifleman, OpFor Sniper, and OpFor Grenadier (rocket-propelled grenades). Each type has different variables that specify how to arm the player, how to increase stress and move for cover, etc. Each one was pretty much the same; The OpFor Grenadier was the only one that required a significant change to keep him from firing his weapon until he has completely stood up (To avoid blowing himself up. With terrorists, this is accurate, but looks extremely dumb when he blows himself and three of his friends up for no apparent reason). At the moment, the NPCs are on infinite ammo, but they are capable of switching weapons based on the weapon's weight, clip size, rate of fire, range, and damage depending on where and how much health the enemy has.

@Steve: Yes, the close formation is an annoying problem. I'm going to stick in a squad formation feature so that they would follow the leader single file or assume a wedge formation when non-mobile. I'm thinking I could improve the line-of-fire problem by raycasting in a cone towards the aim point based on their set aim innacuracy. I simply cast one ray outward each time the ai player fires to check to see if a friendly player is in the way--there is still a 1/2 second window between each think for someone to get in the way of a burst of gunfire.
#10
10/01/2008 (4:24 pm)
Bryce:

Looking good when can we see you starting to sell this? I'm really excited and would like to find out when I can get it into my new game... can't wait for release on this looks like it's improving with every post. Best of luck with it my friend. I hope it sells enough to get you to quit your day job. :-)

Will

PS: is the price still going to be around the $30 to 99 I believe you said a few posts ago on it? thanks man can't wait til it comes out. counting the days
#11
10/01/2008 (4:28 pm)
@Will--I'm working on a demo which I'll try to release before September. A Christmas release seems pretty doubtful at the moment, there is still a lot of things I am planning on implementing in the pack and the AI is still missing some important things, such as squad membership changing (changing which AI player becomes the team leader if the team leader dies) and reacting to threats.

Is this still about right Bryce? Early 09 maybe? thanks man,

Will
#12
10/01/2008 (4:45 pm)
Mid to late 09, probably...I'm going to be getting a better laptop hopefully soon (around Christmas) because the computer I'm using kind of sucks. Here's my to-do-before-release list:

*Get a computer that doesn't tell you it cant find an operating system anymore and that can pull off more than 9 frames per second
*Fix squad flanking
*Squad formations
*Fix wild spinning when team leader is close and we try to regroup
*Clean up messy, horribly organized code
*Create alert level system so NPCs will react upon threats accordingly (e.g. search an area if an enemy player is heard, run around and search cover points for threats if we start taking fire/see a friend die,)
*Grenade evasion
*Look at waypoints to figure out where to throw grenades, and make support for throwing grenades at targets above or below the NPC
*Add advanced squad movement, like the bound overwatch
*Cooperate with the door resource to open doors in our way
*Move intelligently around areas so that we watch where the most likely location for an enemy would be

I think that's it.
#13
10/01/2008 (5:11 pm)
A word from the (allegedly ;P) wise .... beware the ides of function creep.....

I can't think of any 3A game that has a successful bounding overwatch system.
#14
10/01/2008 (5:19 pm)
My plan:

Take two members of the squad and call them team A. Take the other two and call them team B (this should only work with at least four members).

Team A uses the cover-to-cover movement feature, but stops upon reaching cover. A flag is set in the squad object, and team B regroups with team A.

Team A moves up to cover again, while Team B is staying put to cover them.

Lather, rinse, repeat until we're at the destination.

-------------------------------------------------------------------------------------------------------

It looks good on paper, hopefully it will look even better in-game.
#15
10/01/2008 (6:37 pm)
Bryce:

Sounds cool. Any chance I can be your test bed while you work on updates and stuff? More then willing to buy a copy now and play test it in my new game while you work out kinks in the kit or add new stuff. Kinda like a beta ir EA version. If not no biggie, just thought the EA route might be on your list and you could kick start your funding a little from those who could use something like this in their game. I myself am more then willing to put up with broken code, and guys who shoot their friends in the face :-)

Anyways just an idea... can't wait to see it out and about. Thanks for considering...

Will
#16
10/02/2008 (2:07 pm)
@Will: Setting up the payment and everything is a bit complicated to me right now, I would rather just finish everything. Sorry if this is a huge setback or anything...
#17
10/02/2008 (2:25 pm)
How much are you going to charge for a beta test? I might be interested as well. AI is something i have been praying to find. send me a qoute and a NDA to racs333@hotmail.com
edit sorry misread that. I would like to be on your list when you get it finished though.
#18
10/02/2008 (3:02 pm)
Bryce:

Nahh not a prob, just hoping that the pack will be easy to cut up to use only the squads for the AI and not my guys. I don't want to have it like Gears of war does, if thats what your shooting for, looked like you was. I'm shooting for something like what your doing with less depending upon the AI to be a part of my team, but don't get me wrong, the squad on the AI side sounds good. Will it be easy to switch between having AI as your friends if you want a squad like game vs me against a squad of AI? Can I switch somehow between them easy with script? That's why I was wanting to buy it now, as that looked like how it was playing out. Thanks for the info and best of luck man,

Will
#19
10/02/2008 (3:20 pm)
@Will
If you mean adding an AI player that isn't part of the squad, then that's easy. The spawn function for the ai looks like this:
spawnai(team,spawn marker index,type);

When you spawn into the demo game and you clear out the first set of guys, type spawnai(0,25,3) into the console and watch the balcony that the rockets were being shot at you from. Eventually, a terrorist rifleman will run up, notice you, take cover, and engage in a little gunfight with you. Changing the third parameter to 4 will spawn a sniper, 5 will spawn a grenadier (1 and 2 are for the marines). The squads are essentially just individual ai players linked together--you don't have to put them into or spawn them as a squad. The three snipers on the rooftops by the overturned barrels and all terrorists running around the storage containers at the end work this way. Does that answer your question?

@Edward
Not too sure yet. I'm probably going to ask for three to five volunteers (I won't charge) when the kit is finished to implement this into their own games and see how it goes. If all goes well, I'm thinking this should go around $20-30 a pop
#20
10/02/2008 (4:07 pm)
Bryce:

Yup that answers that... thanks for the quick reply, again, can't wait for it. Really good work so far man.

Will
Page «Previous 1 2