Wednesday, 21 August 2013

Wednesday State Power

I Made The Right Decision

Remember that fateful decision to hack in the ladders, and then my second decision to write an editor for the crouch animations and my day today was to finish that and add more animations to it form the main AI prototype. Well it turns out the 'other' animations required where equally 'interesting' and the editor plus state engine sub-system thingies worked amazingly perfectly, and probably saved me hours of frustration too!

Character Enjoying A Quick Roll

My prototype can make the character relax, stand at arms, crouch, move in different directions, roll to a crouch, roll back to his feet, leap over invisible sandbags, fidget in stood and crouch positions and lots more things I have forgotten for now. The bonus is that it all does this with perfect transitions from state to state which means no glaring switches of animation and ruining the smooth flow of the characters through the game.

Alas I got carried away and it's now 4AM (again) but I found time to clean up the routines part way through my additions which means it's now a separate module that can drop into the AI proto which will happen tommorow now. This system will replace the hacked animation code currently in there, minus the ladders which I dare not touch lest it suck me into four more days :)  I am pretty much decided to use my new sub-system on ladders and stairs as well, but I want to finish animated combat to get back on schedule somewhat.

The Trinity Of AI

As I walked the dog earlier today I got to thinking about blogging the nuance of the Reloaded AI system, and the trinity which will make it all realistic. The first level is Paul's AI bots, which in their robotic style move to locations, rotate to and track down targets, work out cover positions and firing patterns. Imagine this as the 'brain' of your enemy, thinking where they should go and what they should shoot at.

The second level is the new animation sub-system which handles how the 'real character' animates and moves to create smooth transitions between each of these states.  The states of course provided by the AI bot, but thanks to the smoothing techniques of the sub-system the 'real' object trails behind the AI bot a fraction. This gives the impression the enemy knows what they are 'going' to do, and subtle visual clues are evident in the sub-system transitions (such as the head-turn you saw in a previous video).

The third and final level is the wonderful details in the animation itself, thanks to Mark. Each animation brings out human traits like swatting a fly away from a face, looking around cautiously and shifting his weight when standing still for too long.

Combined together, they form a potent enemy, that would look real, move around the scene in a realistic manner and appear to think for real too.  You could say it's a perfect solution for our REAL-OADED product! [shudder -Ed]

Signing Off

Any video today would be a bit random and drawn out as there are a LOT of animations coded now but it really would not reveal any more of the tech background than you have already seen. I think the next good video is when all these animation states and transitions are tied to the AI bot and demonstrating a semblance of combat.

4 comments:

  1. Great work Lee seeing reload coming along like this is GREAT. I love the way you tackle the Hi Tec problems in the “subsystem thingies” LOL

    ReplyDelete
  2. Ok question. If I make a model dude. How would I get him to move like your dude. Will there be some way to attach the animation biped to my model or do I have to do my own animation set and rig and use your ai . Just so I know cheers

    ReplyDelete
  3. curious as well science man

    ReplyDelete