RtsAi

The in-sim computer opponent (rts-extension m6-plan §M6P).

In the namespace octomy::rts. Declared in src/libs/librts/rts/ai/RtsAi.hpp.

Detailed description

think() reads the world through RtsSim's const queries and returns the seat's commands. One think runs, in this order: defence or attack, then modes and abilities, then the economy (gather, supply, structures, workers), then the army's production, then research. Each step skips a unit that an earlier step already gave an order, and spends from a budget that earlier orders already reduced, so one think never asks for more than the seat can pay.

Related: RtsSim::setAiSeat() and AiProfile.

In this section