-
Notifications
You must be signed in to change notification settings - Fork 51
Description
As I started to work on #137 , I realized that I'd started adding the structure for not-exactly what that is (AI deciding what to build in cities dynamically), but rather the structure for a strategic high-level AI.
That isn't necessarily bad; they are both things I'd been thinking about how to add. And the strategic AI should play a role in what the AI builds in cities. I wound up starting on it first because in my thoughts about how these should work, the strategic layer plays an almost critical role in deciding what to build. There are local concerns, to be sure - don't build a Settler if the pop requirement will never be met, for example. But a lot of the decision comes down to what is necessary to meet strategic objectives. Do we need more cities? More military units? Better exploration? I could make the city production choices a little better than the placeholder hard-coded selection without a strategic layer. But it will be more robust, and soon more effective, if the strategic layer is looped in first.
Thus, this is:
- Include the base structure for strategic AI priorities, including the general structure for how to choose between priorities.
- Include at least two strategic AI priorities. Expansion will be one of them; there will be another simply to provide an example/secondary priority.
- Add a blurb on the Wiki about this. While nothing is final at this stage, I think this will be one of the first areas where the AI has some long-term vision (versus mostly being an experimental placeholder). Pathing is the other area that's kind of at that stage.
This should lead into #137 nicely.
Longer-term, I also envision strategic priorities being a pluggable component, e.g. a mod could add one. We'll see how this all works (in particular, city selection and about 42 million other places eventually having to be able to query the strategic priorities to see if they should affect decisions being made). But if we can get things aligned to make that happen, I think it opens up a fair amount of moddability when it comes to AI behavior, with only a subset of it needing to be modified to get those effects.