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

Improve AI excess power management #14594

Merged
merged 5 commits into from Feb 27, 2018

Conversation

Projects
None yet
4 participants
@reaperrr
Copy link
Contributor

reaperrr commented Dec 28, 2017

This allows to scale the minimum excess power that the AI is targeting, while also allowing to set a cap. Combined with removing power plants from BuildingFractions, this should prevent the mod AIs from building too many excess power plants, while building enough to maintain a sufficient power reserve.

Fixes #14586.

@Arular101
Copy link
Contributor

Arular101 left a comment

👍 Tested all mods. Nicely done!

The powr and apwr from the NavalAI can be removed too.

@Arular101

This comment has been minimized.

Copy link
Contributor

Arular101 commented Jan 27, 2018

Maybe the maximum excess power in D2K should be reduced a bit. Because in some maps there is not much build space, and the AI keeps on building structures that it can't place down. Resulting in canceling the building and starting it again. Maybe with less power plants it has enough room to place the last couple of buildings.

reaperrr added some commits Dec 28, 2017

Add more configurability to AI MinimumExcessPower logic
Allows to scale the targeted minimum excess with building count as well as define a maximum cap to avoid overproducing powerplants.
Prevent RA AIs from building too many (advanced) power plants
While scaling minimum excess power with base size to make sure they don't build too few, either.
Prevent TD AIs from building too many (advanced) power plants
While scaling minimum excess power with base size to make sure they don't build too few, either.
Prevent D2k AIs from building too many wind traps
While scaling minimum excess power with base size to make sure they don't build too few, either.
Prevent TS AI from building too many (advanced) power plants
While scaling minimum excess power with base size to make sure they don't build too few, either.

@reaperrr reaperrr force-pushed the reaperrr:ai-power-tuning branch from e20011a to 7904f36 Feb 21, 2018

@reaperrr

This comment has been minimized.

Copy link
Contributor Author

reaperrr commented Feb 21, 2018

The powr and apwr from the NavalAI can be removed too.

Done.

Maybe the maximum excess power in D2K should be reduced a bit.

Reduced from 300 to 200 for now.

@Smittytron
Copy link
Contributor

Smittytron left a comment

LGTM

@reaperrr

This comment has been minimized.

Copy link
Contributor Author

reaperrr commented Feb 27, 2018

@OpenRA/engine-hackers Could one of you take a look as well? I'd like to avoid using the admin-merge...

@abcdefg30 abcdefg30 merged commit 700c46d into OpenRA:bleed Feb 27, 2018

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@abcdefg30

This comment has been minimized.

Copy link
Member

abcdefg30 commented Feb 27, 2018

@reaperrr reaperrr deleted the reaperrr:ai-power-tuning branch Mar 9, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.