AI Colony

This page shows the mechanics of AI colonies in story missions and extra missions.

## **Descriptions**

You can only control 1 colony in a mission or a freeplay game. AI colonies are other colonies that aren't under your control. They use the same mechanics as your colony. Each colony is assigned to a different color and a different number

An AI colony is defeated when its queen is dead. Each tile is deleted every 0.5 second afterward and returns 66% of the building cost. Food is changed accordingly to reward the last attacking colony.

Because actual players are smarter and more responsive, AI colonies have to cheat in certain missions and always start with prebuilt nests to provide challenges. The cheat is usually food injection when certain conditions are met.

Other enemies are always hostile to AI colonies.

## **Behaviors**

### **First generation**

First generation AI colonies can only send ants to designated locations on the map, following a strict guide. They can't respond to danger or resource shortage.

First generation behaviors appear in:

* **Queen of the Hill**

* **Babysitting**

* **Tug of War**

* **Tug of War 2**

### **Second generation**

Second generation AI colonies can occasionally check specific locations on the surface for resources. Gathering groups will gather everything and attack everything on their way to the harvest sites. They are kept at the most recent harvest sites if no resource can be found.

Attacking groups are usually kept around the queen and are only deployed to invade enemy nests or to protect gathering groups. They are prevented from gathering.

Gathering groups will retreat back to the queen when they take enough casualties. They either return to the sites with attacking groups or move away completely.

AI colonies usually respond only to your marker placement. They don't respond to nest invasion.

If AI colonies only have queen workers and have no food left, they stay holed up underground.

Second generation behaviors appear in:

* **Possibly the Final Experiment**

* **The Harvest**

* **The Other Foot**

* **Hibernation**

* **Adventure**

### **Third generation**

Third generation AI colonies can frequently check small squared areas on the surface every frame for resources. Gathering groups will gather everything and attack everything on their way to the harvest sites. They are kept inside if no resource can be found.

Gathering groups are prevented from gathering resources and attacking enemies if they are taking aphids.

Attacking groups are usually kept around the queen. They are only deployed to invade enemy nests or to protect gathering groups. They are prevented from gathering resources.

AI colonies don't respond to you marker placement. They don't respond to nest invasion either.

AI colonies respond to battle anywhere by calculating if they can succeed. If it is positive, all control groups move to the sites to overwhelm enemies. If it is negative, they retreat back to the queen and wait for the threats to leave.

If AI colonies only have queen workers and have no food left, they stay holed up underground.

Third generation AI behaviors appear in:

* **Cold Blood**

* **A Bridge Too Far**

A modified vesion of third generation behaviors is currently used in freeplay.

## **Nest building**

Each underground map has a predetermined nest design for the residing colony. AI colonies chooses to build and upgrade on their own, within a certain guideline. They can only build hexagon chambers and can't build highway.

## **Trivia**

* AI colonies were not meant to be in the game until John adamantly pestered Liam to keep actual functional nests in **Queen of the Hill**. He ported the code of the enemy colony in **The Harvest** into freeplay later on and made it work, which convinced Liam to focus on building better AI colonies for future missions and freeplay.

* Second generation AI behaviors are based on leafcutter ants in real life.

## **References**

1. ↑ https://m.youtube.com/watch?v=K\_FNnDNe1Dw&t=2468s
2. ↑ https://www.youtube.com/watch?v=K\_FNnDNe1Dw