- Joined
- Dec 3, 2016
- Messages
- 93
- Reaction score
- 7
Hello!
I know that game is alpha now, but I think this AI control is important and should be implemented as soon as possible, because of a problem. I've seed similar suggestions, but this would connect best of them as I guess.
The problem: AI configuration is narrow and not enough to control AI. For example, missile/cannon drones prefer moving away and miss their target in battle (you can't make them to keep distance you want). You can't control AI as you want to. You just able them to move in some sector, fight, idle and some few more options.
Suggestion:
It will resolve: that big turrets/ships try to hit small and fast ships when they can't hit them. And some sort of irrational behavior of AI.
What do you think about it?
//Status: 60% done
//TODO more detailed description of suggested configurations
I know that game is alpha now, but I think this AI control is important and should be implemented as soon as possible, because of a problem. I've seed similar suggestions, but this would connect best of them as I guess.
The problem: AI configuration is narrow and not enough to control AI. For example, missile/cannon drones prefer moving away and miss their target in battle (you can't make them to keep distance you want). You can't control AI as you want to. You just able them to move in some sector, fight, idle and some few more options.
Suggestion:
[Orders]
We can add some orders to a fleet and/or a single drone:
It will resolve: that drones moves as they want and you can't control them while in a battle.
We can add some orders to a fleet and/or a single drone:
- Attack target.
- Retreat.
- Some navigation orders from navigation suggestion (move to an object, orbit, keep distance...).
It will resolve: that drones moves as they want and you can't control them while in a battle.
Needs to add some AI configurations:
For example:
- Target priority: faster, slower, bigger, smaller, closer, farther, "shielder", "less shielder", most armored, less armored, most attacked, less attacked, most damaging, less damaging, most damaged, less damaged and A LOT more (possible)...
- Action priority: fight, support, mine.
- Facing to the main target (should be disabled for turrets): front, top/bottom, side, mixed (very important, because some ships use turrets that can to fire only while ship is side-faced).
- Tanking priority (should be disabled for turrets): shield/armor/mixed, speed, range.
- Shield: ship will prefer to use energy to recharge shields.
- Armor: ship will prefer to keep facing to the enemy.
- Speed: ship will prefer to change it's speed against firing.
- Range: ship will prefer to get max range when it's not far enough, after that it will prefer to fire. Also, need to add an optimal range configuration for this.
- No tanking priority: ship will prefer to fire (unnecessary, because of it's might be implemented as tanking priority: range with optimal range 100 m or about).
- Retreat at (should be disabled for turrets): no retreat, enemy detection (will avoid any battle), reaching shield hp level, loosing shield, reaching armor level, loosing armor, reaching hull level and another.
- Formation priority (should be disabled for turrets): 0 - closest to the front, 999 - farther from the front.
For example:
- Fighter (anti-bomber small fast ship):
- Target priority: closer, smaller, most damaging.
- Action priority: fight.
- Facing: front.
- Tanking type: speed.
- Retreat at: 10% of armor.
- Formation priority: 1.
- Bomber (anti-capital small fast ship):
- Target priority: bigger, slower, most damaging, most attacked, most damaged, "less shielder".
- Action priority: fight.
- Facing: front.
- Tanking type: speed.
- Retreat at: 20% of armor.
- Formation priority: 5.
- Anti-air turret:
- Target priority: closer, smaller, faster, most damaging.
- Action priority: fight.
- Battleship (big ship without manual weapon, but with heavy turrets on it's sides or top):
- Target priority: bigger, slower, most damaging, most attacked, most damaged, "less shielder".
- Action priority: fight.
- Facing: front.
- Tanking type: shield, armor.
- Retreat at: 20% of armor.
- Formation priority: 15.
- Capital shield support turret:
- Target priority: bigger, "less shielder", most attacked, slower.
- Action priority: support.
- Drone shield support turret:
- Target priority: faster, smaller, "less shielder".
- Action priority: support.
Every tick AI will update some code. User can code it as he want. And save template too.
All may be the same as in variant 1, but target priority.
Drone will use a method to choose target. Rule is easy: drone will attack entity with highest priority value. Priority value = getPriority(args);
For default this method will be:
int getPriority(Entity entity)
{
if(!isEnemy) return 0;//It mean that drone will not attack target if it is not enemy.
if(isOutOfRange()) return 1;//It mean that drone don't want attack target if it is out of weapon's range. But it will attack it if here is no other enemies.
if(isAlreadyAttacking()) return 100000;//If drone is already attacking, it will continue;
return 100000/range;//Else it will attack closest enemy.
}
For example, bomber's code:
int getPriority(Entity entity)
{
if(!isEnemy) return 0;
int priority = 0;//Used to calculate
priority = (10000/ (range + 3000)) * entityMass * (1.25 - entityShieldLevel) * (1.25 - entityArmorLevel) * (1.25 - entityHullLevel);//Will want to attack closest biggest and most damaged entity
if(isAlreadyAttacking) priority *= 2;//If already attacking it, it will want to continue
return priority;
}
//If range = 3000, mass = 50000, shields = 100%, armor and hull = 100%, result will be = 1302;
//If range = 3000, mass = 50000, shields = 25%, armor and hull = 100%, result will be = 5213;
//If range = 3000, mass = 50000, shields = 0%, armor = 50% and hull = 100%, result will be = 19531;
//You can make a desicion
//For example, bomber will not be interesting in attacking of light ships like:
//Light ship 1: range = 3000, mass = 1000, shields = 0%, armor = 50% and hull = 100%, result will be = 390;
//Light ship 2: range = 500, mass = 2000, shields = 0%, armor = 50% and hull = 100% result will be = 1399; As you can see 1399 is more than 1302, so bomber will choose to attack damaged medium ship against non-damaged heavy ship. It allows you to choose what you want.
For example, fighter's code:
int getPriority(Entity entity)
{
if(!isEnemy) return 0;
int priority = 0;
priority = (5000 / range) * (500/(abs(entityMass - 150) + 1) * (200 + entitySpeed);//Drone will want to attack fastest closest ship with mass closest to 150.
if(isAlreadyAttacking) priority *= 10;
return 0;
}
All may be the same as in variant 1, but target priority.
Drone will use a method to choose target. Rule is easy: drone will attack entity with highest priority value. Priority value = getPriority(args);
For default this method will be:
int getPriority(Entity entity)
{
if(!isEnemy) return 0;//It mean that drone will not attack target if it is not enemy.
if(isOutOfRange()) return 1;//It mean that drone don't want attack target if it is out of weapon's range. But it will attack it if here is no other enemies.
if(isAlreadyAttacking()) return 100000;//If drone is already attacking, it will continue;
return 100000/range;//Else it will attack closest enemy.
}
For example, bomber's code:
int getPriority(Entity entity)
{
if(!isEnemy) return 0;
int priority = 0;//Used to calculate
priority = (10000/ (range + 3000)) * entityMass * (1.25 - entityShieldLevel) * (1.25 - entityArmorLevel) * (1.25 - entityHullLevel);//Will want to attack closest biggest and most damaged entity
if(isAlreadyAttacking) priority *= 2;//If already attacking it, it will want to continue
return priority;
}
//If range = 3000, mass = 50000, shields = 100%, armor and hull = 100%, result will be = 1302;
//If range = 3000, mass = 50000, shields = 25%, armor and hull = 100%, result will be = 5213;
//If range = 3000, mass = 50000, shields = 0%, armor = 50% and hull = 100%, result will be = 19531;
//You can make a desicion
//For example, bomber will not be interesting in attacking of light ships like:
//Light ship 1: range = 3000, mass = 1000, shields = 0%, armor = 50% and hull = 100%, result will be = 390;
//Light ship 2: range = 500, mass = 2000, shields = 0%, armor = 50% and hull = 100% result will be = 1399; As you can see 1399 is more than 1302, so bomber will choose to attack damaged medium ship against non-damaged heavy ship. It allows you to choose what you want.
For example, fighter's code:
int getPriority(Entity entity)
{
if(!isEnemy) return 0;
int priority = 0;
priority = (5000 / range) * (500/(abs(entityMass - 150) + 1) * (200 + entitySpeed);//Drone will want to attack fastest closest ship with mass closest to 150.
if(isAlreadyAttacking) priority *= 10;
return 0;
}
It will resolve: that big turrets/ships try to hit small and fast ships when they can't hit them. And some sort of irrational behavior of AI.
What do you think about it?
//Status: 60% done
//TODO more detailed description of suggested configurations
Last edited: