planets troops increasing even with attacking ships in orbit

Describe your experience with the latest version of FreeOrion to help us improve it.

Moderator: Oberlus

Forum rules
Always mention the exact version of FreeOrion you are testing.

When reporting an issue regarding the AI, if possible provide the relevant AI log file and a save game file that demonstrates the issue.
Message
Author
User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 13587
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

Re: planets troops increasing even with attacking ships in o

#16 Post by Geoff the Medio »

Oberlus wrote:The compiled version, pulled from github two days ago, has the same problem.
Update to the latest.

User avatar
Oberlus
Cosmic Dragon
Posts: 5715
Joined: Mon Apr 10, 2017 4:25 pm

Re: planets troops increasing even with attacking ships in o

#17 Post by Oberlus »

OK, thank you, I'll do it ASAP (probably this evening) and report.

User avatar
Oberlus
Cosmic Dragon
Posts: 5715
Joined: Mon Apr 10, 2017 4:25 pm

Re: planets troops increasing even with attacking ships in o

#18 Post by Oberlus »

The invasion button appears, and it works. But it seems something is still broken for the AI, it wont invade any planet, despite having visibility, defenses down, armed ships and more than enough troops for the invasion in orbit of the planet for several (5+) turns.

User avatar
Dilvish
AI Lead and Programmer Emeritus
Posts: 4768
Joined: Sat Sep 22, 2012 6:25 pm

Re: planets troops increasing even with attacking ships in o

#19 Post by Dilvish »

Oberlus wrote:The invasion button appears, and it works. But it seems something is still broken for the AI, it wont invade any planet, despite having visibility, defenses down, armed ships and more than enough troops for the invasion in orbit of the planet for several (5+) turns.
Yes, the AI hasn't yet gotten these updates from CurrentMeter to InitialMeter that the human UI just got. I'll be trying to get a PR together for that later tonight, hopefully in time for a little review and testing and then hopefully getting merged before next week's build.
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0

User avatar
Dilvish
AI Lead and Programmer Emeritus
Posts: 4768
Joined: Sat Sep 22, 2012 6:25 pm

Re: planets troops increasing even with attacking ships in o

#20 Post by Dilvish »

The fix for AI invasions of generally-shielded planets was a simple fix, I did a quick test and pushed it to master rather than holding it up with a PR.

I'll also do a review of other AI uses of CurrentMeter and decide which ones would probably be better as InitialMeter, depending on how clear the decision seems I may push it directly or put up a PR.

Side note, I also put in a fix for SP_SLY-- they had been suicidally dejected over their recent affliction with BAD_SUPPLY and were essentially not colonizing at all, that's fixed now.
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0

User avatar
Dilvish
AI Lead and Programmer Emeritus
Posts: 4768
Joined: Sat Sep 22, 2012 6:25 pm

Re: planets troops increasing even with attacking ships in o

#21 Post by Dilvish »

dbenage-cx wrote:Given a system with only a single planet with Ancient Guardians, still seeing +1 troop gain where ships have attacked for 5+ turns.
This issue is still ongoing, I'm going to make a github Issue on it. One AI planet I was camped on was still getting troop regen of 5 per turn even though it was under constant attack by my ships, and a similar thing happened when one of my planets was under blockade from an AI.
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0

User avatar
Dilvish
AI Lead and Programmer Emeritus
Posts: 4768
Joined: Sat Sep 22, 2012 6:25 pm

Re: planets troops increasing even with attacking ships in o

#22 Post by Dilvish »

This troop regen glitch is proving tough to corral. In the meantime, the AI has probably been under-performing and making testing less enjoyable, so I've put up a PR that includes both one 'normal' invasion planning improvement for the AI, plus a temporary adjustment basically informing the AI of this regen glitch. I suggest any active testers cherrypick both commits for now.
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0

User avatar
Oberlus
Cosmic Dragon
Posts: 5715
Joined: Mon Apr 10, 2017 4:25 pm

Re: planets troops increasing even with attacking ships in o

#23 Post by Oberlus »

I found a case in which troops of planets under siege are still increasing. I think the key might be here:
Geoff the Medio wrote: Sun Feb 11, 2018 10:09 pmShould meter regen be gated by when a battle occurred in the system, or by when the planet was attacked? Currently it's the latter, possibly with some lingering buggy - 1's in the scripts.
If the colony under siege has no defenses because they were wiped out in turn T-1 and the owner Empire has no defense regeneration techs, then on turn T+0 the colony won't be attacked and so its troops will increase. Does this make sense?

I certainly would expect my ships to keep shooting at the colony to keep troops at bay while more of my troopers are incoming.

Post Reply