Well i play more with the ideas i have about it , and work to try to materialize dem .
I wanted to talk about the AI tactics , and this is perhaps the right place .
An other thread of mine talk also about AI , but from a code perspective :
http://forums.vega-strike.org/viewtopic ... 27&t=19807
But without regards to any kind of code , i think here about the strategy .
Human strategy front of an actual AI that only have this file :
... as Tactics .#ifndef TACTICS_H_
#define TACTICS_H_
#include "order.h"
class CloakFor : public Order
{
float time;
float maxtime;
bool enable;
public: CloakFor( bool enable, float seconds = 0 ) : Order( CLOAKING, 0 )
, time( 0 )
, maxtime( seconds )
, enable( enable ) {}
void Execute();
~CloakFor();
};
#endif
I said that i won't talk about code , so this previous argument is good enough to introduce the subject of this thread .
AI TACTICS
Chapter 1 : Following orders AND "think" pass .
Today , AI is only able to follow orders , not to think .
We , human players , have individual tactics , and skills for pilot a vessel or trade or fight
or ... etc . Between each Action pass ( you press a button , moove joystick etc ...) , we
think to what we gonna do next .
AI today is living in an Action event context , triggered by a script .
Perhaps there is a limited think time in the actual orders ( compute relationship , vessel
control ) , but not linked to the dynamic universe .
It's like if the universe generated the AI only for events , not for persistence .
I agree with the fact that if your AI lives and die only in a vessel cockpit , for only one
mission or quest script , you don't need to give him a brain : SHUT UP , TURN LEFT , ACQUIRE TARGET , FRIEND OR FOE , OPEN FIRE , MISSED ->DO IT AGAIN UNTIL DEATH
But if we want to have NPC Persistency in the gameplay , they ideally could be perceived
as Players . And players have time to think .
Chapter 2 : AI TIME FOR THINK.
In the core of the c++ engine , i've read that render operations + physics occurs at frame
level . It will try to find that part of code to show you . But ...
What i want to introduce as idea is a AI TIME , in that main loop .
Before trying to define quantity ( how much cost of time/frames/physics_steps because of the AI CALLBACKS LOOPS ) , i will try to find " when to think " .
Thinking is not apply orders .
The AI will ALWAYS follow orders , send by itself .
What kind of orders ?
_REST : automation mode , mean set-autopilot-on for vessels , sleep for NPC .
With a REST order , the AI will never think . ( Make the AI have a dream is very challenging ... ) .
_ATTACK :
Say i am a AI agent : It's time for me to think . ( without thinking you are all deads )
I received the order to attack ,
first question is :
WHO ?
second question :
WITH WHAT ? ( perhaps that is the question in my signature , and it should be the first question , strategically speaking ) .
If i have no more missiles or guns damaged , i must answer to my AI Authority : " NEGATIVE " .
I stay safe by keeping my distance , and wait for orders :
They want me to die , i follow ( i am a stupid AI ) .
They want me to live , i follow ( i am a stupid AI but i had chance this time )
The question 3 ( free ) will never occur : " what the hell am i doing here ? "
exception :
Perhaps a very special pirat's AI NPC unit should be able to think the 3rd stage of thinking
And this numeric guy ( male or female ) could be a only thinking unit .
Other AI units execute orders , with different levels of freedom ( time to think ) .
The same could apply for all the Factions .
Chapter 3 : Different ways of thinking .
In the case of Aera's faction , theMeritocracyis something sexy to modelize ( for a geek ofcourse ) .
A blank page in the wiki to fill in about it : http://wiki.vega-strike.org/Terminology:MeritocracyMeritocracy (merit, from Latin mereō: “earn” + -cracy, from Ancient Greek κράτος, kratos: “strength, power”) is a political philosophy that holds power should be vested in individuals according to merit.[1] Advancement in such a system is based on intellectual talent measured through examination and/or demonstrated achievement in the field where it is implemented.
But oligarchy is sexy also : http://en.wikipedia.org/wiki/Oligarchy
That notion of states is a basic requesite in a AI system .Oligarchy (from Greek ὀλιγαρχία (oligarkhía); from ὀλίγος (olígos), meaning "few", and ἄρχω (arkho), meaning "to rule or to command")[1][2][3] is a form of power structure in which power effectively rests with a small number of people. These people could be distinguished by royalty, wealth, family ties, education, corporate, or military control. Such states are often controlled by a few prominent families who typically pass their influence from one generation to the next, but inheritance is not a necessary condition for the application of this term.
We have two examples of way of thinking , each depending on states .
That is enough to begin to draw a root for thinking .
Then push branches from it , with different implementation of states .
To each governement , a state machine ... with rules that children AI agents apply ,
thinking or not .
A practical example with a fighter squadron :
Who is thinking ?
The authority in a fighter group is the leader .
So the Leader has thinking attribute set on .
Others are following orders .
But ... The Leader is also a Follower , and he reports status to the authority that has
the THINKING PRIVILEGE .
Chapter 4 : THINKING PRIVILEGE .
How is done the attribution in each Faction .
Describe the specialization in thinking ;
Economy , Astronomy , Military , Spirituality or Moorality etc ...
Thinking is for a goal , so what is to be defined are goals , the core of the AI cycle .
THINK : " What is my goal " -> read in XML
THINK : " Can i do that now " -> use c++ evaluation code or previous record in the timeline ( i know the ennemy vessel will be in my sight in 1/10 secondes if i keep that way , so just wait and return ok )
Or in a trade context :
I am in a merchant guild and received orders to buy some rare gaz elements in that system , but the prices are very high .
THINK : " Can i do that now " -> look in the priorities table and ask authorities() .
Authorities in economy will think and reflect the economical situation in their selling prices.
Back to this chapter , the privilege of thinking should be attributed to persistent NPC ,
ideally that can't die . ( They have a fleet all around them that are their remparts , they
will never go in front line etc ... But you can talk to them in bases or stations )