Internal Demo That Is
I have been looking forward to creating the visual demo to show off the AI so far, and so today has been fun. Had to jump back to the core module about ten times to refine and clean more of the code and resource usages, but eventually the visits became less frequent and I could start playing inside the demo.
By demo, I mean a prototype with terrain, physics, player gun sticking out, assets scattered here and there, and the hero of the hour, our AI character. As I write this he is running about, doing his patrol, reloading his gun and using the newly associated physics capsule to control his progress through the scene. Any hills he runs over them, obstructions he stops and of course the player cannot run through him and he cannot run through the player. It's all very civilized. That is not to say he is finished, and not by a LONG chalk! He acts rather scatty when standing still, he does not melee, he does not seem to see me half the time, his general movement behavior is erratic and generally he does not behave like he does in my AI prototype. Friday will be about calming him down and getting him looking as good in the demo as he does in the AI proto room.
The physics integration with the character went very smoothly, thanks to a bit of thinking before I started coding. I was going to attach the physics to the visual object and leave the AI entity object to act as the 'advance scout' to reflect the characters mind. After reflection, I realized I want his projected future position to have the physics awareness so he does not project his final destination through recent rubble and other dynamic obstacles. To do this, I simply decoupled the object from DarkAI, and then used a velocity force on the newly created physics object using the AI entity coordinates. I grabbed a screenshot showing this trinity of 'entity position, physics object position and visual object position' but my PC ate it so I am guessing fate wants you to wait for an even better shot.
I also spotted that my physics prototype and therefore most of the module was using hard coded resource values. I will need to deal with this as such code will totally trip up the final integration step.
The Next Bit
My main goal, aside from the bits and bobs above, is to add health, shooting and impact deaths to the demo prototype on Friday. This way I can shoot the character, he can shoot me and we can have a good combat simulation. Before I moved over to demo work, and part of the clean-up of the code, I added two more characters to the AI proto and it was great to see them in action. Even though I had not coded it, the AI entities would flank me, some would fire, some run up to me and kick me, others retreating to reload and as few as three characters kept my player pretty busy almost all of the time. I have a good feeling that players of Reloaded games will get some decent high octane game-play.
Signing Off
My artist has been plagued with power cuts and it's possible I won't get my combat building before the demo day which is Monday. The good news for all concerned is that with some liberally scattered sand bags, more characters roaming the hills and a functioning player weapon, I should be able to demonstrate a variety of AI behavior in the actual terrain setting which was my goal three weeks ago.
Three weeks seem to have come and gone! The more I build feature upon feature, and start to see the combined results, the more I am convinced I have no earthly business writing such an ambitious piece of software. This is no longer an augmentation of an existing product, it's a bottom-up rewrite of almost every component and considering the last one took almost 2 years I am amazed I have gotten this far. Fear not readers, I am not feeling the strain or loosing faith, I am simply gobsmacked that me and a few guys have cobbled this together in a relatively short time and it's starting to look seriously good. More than that, the potential of this product is insane, and I would not be surprised that Lee splits in two at some future point just to keep up with the ideas that need coding.
I will see if I can prepare a nice screen shot or video for you Friday (probably posted Saturday early hours) as we're in demo country now and the visuals are much much nicer!
Ohai Lee. I have found Jeff Orkin's MIT site in-case you want to contact him on potentially creating an A.I. middleware down the road after FPSCR is released, which may well be worth a try:
ReplyDeletehttp://web.media.mit.edu/~jorkin/
It even includes his twitter account, so if you want to tweet him if you have time, there's your chance. :D He is working on a A.I. system currently, but he may be able to at least give you advice on A.I building. Plus, you could also lend them a hand for there A.I. system if you so please. Anyway, please reply & thank you for your time.
Regards, Littlevince104
hello Lee,
ReplyDeleteno segments showing in demo? with ladders etc..
Mr Orkin has been a busy chappy in the world of AI. He has kindly produced a dissertation on his thoughts around the next generation of AI and it's pretty advanced stuff. I've yet to read past the abstract but the general idea is that anytime anyone plays a Reloaded game, I feed player behaviors back to a central database and through pattern recognition produce a character that behaves in a very human way. Essentially throwing away hacked state engines and scripts, empowering characters with a sort of collectively grown neural net of behaviors and reasoning. I imagine such a character in a computer game would be pretty scary, as he drops his own weapon, collects all your power-ups and proceeds to complete your quest ahead of you ;) The closest I've ever coded in this direction is recording ghost data from the player and replaying it back through an enemy character. It's quite freaky how life-like it is, even though it's a complete hack. Exciting times ahead for AI!
ReplyDeleteAwesome stuff Lee! Personally, I wouldn't be surprised if you split into another 3 or 4 Lees. Think of the possibilities of an army of Lees! :)
ReplyDeletesees title: DEMO!
ReplyDeletereads subtitle: I TRUSTED YOU!
I'm just a big tease (all four of me)
ReplyDelete