After putting together the AI Framework yesterday (About 5 hours of work) I was eager to try it out so today I switched our viewing system over to use the AI Framework. Basically this tested the observers (things that gather information for the player and AI), observations (what the observers produce) and objects (what looks at the observations. Things like ships and fleets). In this case the an object is hooked up to the player which sends the observations out to the client to render.
So now I need to optimize the framework, document how to use it for our other developers, and test/use the other half. The other half of the framework consists of the objects producing urges which are then applied to the relevant controls (what drives ships, controls guns etc) which in turn will produce urges for sub controls (fire thrusters, shoot weapons and stuff like that).
To test this half of the framework we will have to control some ships, so expect to see some controlled ships eventually, but you might get better client side camera control (By Matt) and some lag/graphics improvements first.
Now just for fun, some neat features and random facts about our plans for the AI Framework:
- The player is just one of many AI Objects
- You only see what your ships and stations (Observers) can see. (Fog of war)
- Important old observations (ones that objects are still interested in) are keep so you can see where stuff was when it went out of site (This is possible, but if/how it will be displayed is not decided), and the AI can act on it.
- AI Objects know when to compromise and when to make decisions (or do both).
- AI Objects communicate (share urges). Allows fleets to call for backup, lets ships concentrate fire on the enemy that they could (collectively) kill the fastest or is doing the most damage, can let ships ask for help if they are taking heavy damage (they can ask ships to intercept the damage and/or focus fire on the enemies doing the damage)
- Fleets have AI Objects just like ships so there is intelligence on both levels and communication on and between both levels. Ex: A ship can ask the fleet to retreat. If enough ask (how much demand is required will be adjustable) it will retreat.
- Priority scalers and compromise settings can be adjusted. This means we can allow players to do things like up the importance of the protection of a given ship or adjust the factors involved in choosing a target enemy.
- Players can rebalance decisions to adjust like deciding to advance, hold or retreat.
- Compromise settings can be adjusted allowing things like adjusting the importance of maintaining formation in retreat or allowing/disallowing individual ships to retreat.
- And lots of other stuff!
(random idea: using almost dead ships as battering rams. We could do that…)
Sound cool? Lets hope we can get it all to work.
The main goal of the AI is to not give an advantage to an online player when he is attacking an offline one and manage all the little things the player can't (aiming, thrusting, shooting), but our AI should also add tons on strategy. Fully customized ships and fully customized AI if you want allows for some intense strategy making. We will have to decide how custom we let the AI get, but I'm thinking very custom.
I wasn't really planning to go do the AI Framework, but I had time and Matt is working on the client, so we have some unplanned bonus progress ;)
I will get back to what I should be doing soon (Making the client graphics reasonable and fixing/finishing our database app for ship parts and such).
Well, lots of fun AI information in this post so enjoy and discuss.
- Craig