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

Income from troops parked at temples results in a positive feedback loop #5

Open
neil-rutherford opened this issue Nov 3, 2020 · 0 comments

Comments

@neil-rutherford
Copy link

Overall, this is an awesome game and I really enjoy playing it! That being said, there is a bug with income calculation that affects gameplay.

Toward the end of the game, the last AI parks its troops at a temple, meaning that its troop count is included in the income calculation. It never moves its troops, meaning that it gets stuck in a [use troops to generate income] --> [use income to buy troops] --> [use troops to generate income] --> [...] positive feedback loop. After a few iterations of this, the AI is able to generate a stupid amount of money each turn and grow its army to an unrealistic size.

This affects gameplay because the AI army quickly becomes too large to defeat. If the player figures out how the AI is generating so much money, the player can grow their army the same way and eventually defeat the AI. (I had to look at your code to figure out what was going on.) Otherwise, the AI could either overrun the player or just be unbeatable. Every time the player mobilizes their troops away from a temple to attack the AI, they are putting themselves at a disadvantage (the troops are not at the temple, and are therefore not included in income calculations). Here's what my gameplay looks like now:

image

I'm not quite sure how to fix it, but I'd start at line 1982. Keep up the good work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant