Client

This is the part that facilitates communication between the Stratagus game and the AI code. It keeps both a game state and a way of sending commands to the server in the GameProxy class.

Strategy Manager (stratman)

The Strategy Manager is the Manager that controls everything. It implements Controller (to interact with the Client) and creates the Production and Tactical Managers. It is responsible for making the appropriate calls to its sub-managers to ensure that they can perform their given Tasks.

Manager Class

The Manager Class defines the interface for a task manager that performs a given task. It has several methods that allow it to communicate with both its parent and child Managers.

Strategy Planner (stratplan)

The Strategy Planner is responsible for creating and scheduling a strategy. It can read (and write) a strategy from a file, and passes it to the Strategy Manager in the form of a directed graph of Tasks.

Task Class

This class defines a generic task to be completed by a generic manager. It contains a (unique) String name and String type (specifying which manager to pass the task to). In addition, it has an Arguments field, that wraps a rectangular target region (for the Tactical Manager) with a list of Arguments. Each Argument has a name and value that are interpreted as needed by its specific executing Manager.

Production Manager (prodman)

This Manager is responsible for devising a plan that maximizes resource production and minimizes the time to reach a given resource goal.

Production Planner

This is the part that does the actual planning for a resource goal.

Tactical Manager (tacman)

This Manager controls the military. It spawns Squad Managers (unit micromanagers) as needed to accomplish tactical goals provided by the Strategy Manager.