induktio / thinker

AI improvement patch for SMACX.
https://discord.gg/XdFuwWzzku
GNU General Public License v2.0
74 stars 10 forks source link

Psych behaviour deviates from base game. #78

Open blake-sc opened 3 weeks ago

blake-sc commented 3 weeks ago

I have a size 2 base which with the old psych behaviour would be pacified by a single doctor, however with the new psych behaviour it remains unpacified.

Big picture: I am playing as University on a large map, and am about 30% over the first bureaucracy limit, still not enough bases for superdrones.

Screenshot from 2024-10-06 17-16-42

With the original behaviour, assigning a doctor will convert the drone into a content citizen:

Screenshot from 2024-10-06 17-21-08

However with the 4.6 behaviour, the drone is not pacified:

Screenshot from 2024-10-06 17-16-58

It's hard to tell visually, but to me it looks like the first drone is turned into a superdrone by assigning the doctor, and the superdrone is then only turned into a drone by the 2 psych.

I was not able to reproduce this with a faction other than University (I tested The Hive), so it's possible it could be related to the University's 1 drone for every four citizens, but which I understand should only be kicking in at 4 population.

Zakharov of the University, 2160, Psych Oddity.zip

blake-sc commented 3 weeks ago

Here's another significant divergence which I found on a "triple energy" turn:

Thinker 4.6 Behaviour, 6 talents and Golden Age:

Screenshot from 2024-10-07 13-46-53

Base Game and base_psych=0 Behaviour, 4 talents and no Golden Age:

Screenshot from 2024-10-07 13-46-04

Normally the amount of psych which can be utilized is capped at 2 x base population, although additional Talents from HGP, being Lal etc can still add more Talents.

This means if you have "extra drones", the capped psych has to first go to subduing the extra drones and thus it becomes impossible to achieve a Golden Age through psych spending alone as you then cannot get half your population as talents.

This mechanism seems to be intended to gently punish ICS and nerf University, making it impossible to brute force Golden Ages in a society with extra drones.

It seems the cap has been removed/relaxed in 4.6 (actually, I think relaxed, 4x pop perhaps?), which I don't think is a good thing since the psych cap nerfs things which are too strong anyway. But if it is deliberate then it should at least be clear in Thinker.ini that the flag allows unlimited amount of psych to be utilized.

induktio commented 3 weeks ago

On the first note there seems to be an issue with the way bureaucracy drones are calculated in the base when it also has specialists present. The doctor seems to be doing what it is intended since it actually pacifies the superdrone which becomes a regular drone instead, the issue is in the calculation that happens on the first row. The psych sub window is very good at debugging these since it is also the only place that displays the superdrone icons specifically (main population row had some rendering bug I recall). I will look at this part of the code to make some rewrites preferably so that it would use the original bureaucracy mechanic.

The second part with the psych spending is intentional although it probably needs to be documented in more detail. It was also present in the previous version. Since the original game caps psych spending at 2xbase pop, it's somewhat unfortunate when the additional spending is just wasted. With modified base_psych enabled, any additional spending after this point will count but the marginal cost to pacify one drone starts from 4 psych and it doubles at each drone starting from the third step. I think it is justified to provide some benefit for this spending and in the example you also have a base with 100 energy surplus, no superdrones and lots of psych bonuses to include with it.

blake-sc commented 3 weeks ago

That does seem reasonable, though definitely something that should be documented as it's a dramatic gameplay change for the 5 factions that can only pop-boom with Golden Ages.

induktio commented 3 weeks ago

This issue should now be fixed on Oct 8 build and would recommend everyone to use it instead.