Difference between revisions of "Fire Sustain Guide"

From Gladiabots Wiki
Jump to: navigation, search
Line 3: Line 3:
 
A classic problem in Gladiabots is bots switching targets mid-shot and never getting a shot off. Let's start with a very simple combat AI.
 
A classic problem in Gladiabots is bots switching targets mid-shot and never getting a shot off. Let's start with a very simple combat AI.
  
[[File:Gilberreke-Simple ai-mk1.png|frame|none|A very simple AI]]
+
[[File:Gilberreke-Simple ai-mk1.png|thumb|none|A very simple AI]]
  
 
As you can see, the attack command executed is to just always attack the closest enemy in range. What often happens with this attack is that another enemy walks in closer while you are aiming, causing you to switch to this new target, before having fired a shot. This is almost always a bad idea, but how can we remedy this?
 
As you can see, the attack command executed is to just always attack the closest enemy in range. What often happens with this attack is that another enemy walks in closer while you are aiming, causing you to switch to this new target, before having fired a shot. This is almost always a bad idea, but how can we remedy this?

Revision as of 00:50, 16 February 2020

The Problem

A classic problem in Gladiabots is bots switching targets mid-shot and never getting a shot off. Let's start with a very simple combat AI.

A very simple AI

As you can see, the attack command executed is to just always attack the closest enemy in range. What often happens with this attack is that another enemy walks in closer while you are aiming, causing you to switch to this new target, before having fired a shot. This is almost always a bad idea, but how can we remedy this?

Keep attacking

The first thing we can do is just simply keep attacking any target we're attacking. The game explains this mechanic in the Advanced Training tutorial "Pursue Current Target". I suggest that you redo this tutorial before continuing to read this guide, because it nicely illustrates another problem you can have without a good fire sustain.

File:Gilberreke/sustain1.png
Attack the closest bot in range, attacked by me

Let's add this node to our simple AI. It should precede any other attack nodes and always have the highest priority, so that our bots can no longer switch targets while attacking.

File:Gilberreke/sustain2.png
A simple AI with sustain node