Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Improve the city constructions AI #10516

Closed
PLynx01 opened this issue Nov 17, 2023 · 6 comments
Closed

Feature request: Improve the city constructions AI #10516

PLynx01 opened this issue Nov 17, 2023 · 6 comments

Comments

@PLynx01
Copy link
Contributor

PLynx01 commented Nov 17, 2023

The introduction

I've noticed that most city construction AI ignores most of building uniques. Also, the AI does not have the capability to weight the negative effects of the constructed buildings' uniques.

The suggestions

  • Include more uniques into consideration by city constructions AI.
  • Make AI aware of negative effects of the buildings' uniques.

Why?

Implementing these features will make the AI much smarter, because it wouldn't ignore most of uniques like the current AI.

Moreover, proposed changes will enable the modders to make mods containing more realistic and in-depth effects provided by uniques. If some of these effects are negative, the improved AI would decide whether the positive effects outweigh the negative ones. If so, the AI would choose the building, otherwise it will not build it.

What do you think about my idea?

@tuvus
Copy link
Collaborator

tuvus commented Nov 17, 2023

Hello! I plan on looking at the city construction AI after I rework the worker AI. Can you give some examples of some of the unique combinations that you are thinking about?

@PLynx01
Copy link
Contributor Author

PLynx01 commented Nov 17, 2023

Hello! I plan on looking at the city construction AI after I rework the worker AI. Can you give some examples of some of the unique combinations that you are thinking about?

I am thinking about so-called abstract buildings. They are treated by game like buildings, but they don't represent physical buildings.

They can be:

  • Edicts and decisions (like those in Paradox games, they can have also negative effects)
  • Situations (like epidemics, civil unrest or immigration boom)
  • Other modifiers and parameters (like GDP per capita, public health, crime rate, level of education and pollution)

Many of these abstract buildings would have negative effects that need to be weighted by AI. It needs to decide whether the positive effects outweigh negative ones.

Also, buildings that are not abstract can have negative effects too. The example is the pollution generated by factories.

@tuvus
Copy link
Collaborator

tuvus commented Nov 27, 2023

It's cool that you plan to use buildings as a sort of event. (Thoughts: Do we want to make a more detailed event json object that can be called? How much work would that take?)
Do you think the AI should also look for buildings to sell if they give money or some other effect?

@PLynx01
Copy link
Contributor Author

PLynx01 commented Nov 27, 2023

It's cool that you plan to use buildings as a sort of event. (Thoughts: Do we want to make a more detailed event json object that can be called? How much work would that take?)

There are no random events in unmodded Civ 5, so maybe we should use the buildings as the representation of event.

Do you think the AI should also look for buildings to sell if they give money or some other effect?

In my opinion, it is worth implementing, especially if a building has more negative than positive effects. In order to do this, we need the function hasNegativeEffects() or something like that.

Copy link

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 15 days.

@SeventhM
Copy link
Collaborator

Closing, as I want to move discussion to #11264

@SeventhM SeventhM closed this as not planned Won't fix, can't repro, duplicate, stale Mar 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants