• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.
Showing developer posts only. Show all posts in this thread.
With the newfound power of GalaxyNet the AI, would you say it is on par with AI mods like StarNet?
I have never tried starnet myself so I can not make any statements about how 3.2+starnet vs 3.3 compares.

Like mentioned in previous answers, it will always to make mods to make the AI even better and more minmax so I suspect there will be new updates to such mods that take what was added in 3.3 to the next level
 
  • 1
Reactions:
If there's an unemployed pop (of the correct or lower stratum), and a job opening, will it immediately take that job, or does it have to wait for the monthly tick?

I noticed in the 3.3 Beta that, after I conquered a populated planet (an AI capital), and demolished some districts to build the districts that I needed (food and energy), creating significant unemployment, a bunch of workers of the conquered population ended up unemployed for more than a few months. Their tooltip showed them to belong to Worker stratum, but they would refuse to take the available Mining and Technician jobs that I had just built. I think it would be worth it to speed up this process of the AI taking jobs. I no longer have the save file, but it might be related to this change.
There was a bug on the beta where worker pops would sometimes be unable to take any job if there were unemployed specialist at the same time. Not sure if this was your case here.

With the above system the jobs should go back to work in the following monthly updates at a rate which is much faster than how fast you can build up new districts so overall it should even out pretty fast.

Pop updates caused when you do stuff like building buildings or demolishing stuff will still cause the pop update but it will only shift one pop at a time according to the new system. So when you build a research lab you may have 1 month where only 1/2 of the pops have filled in the specialist jobs, overall this would not matter much in the big picture but it would be possible to fix this as well for the best possible experience :)
 
  • 3
Reactions:
In the 3.3beta, when I turn on multiple jobs with one click (e.g. ctrl+click for 5, or shift+click for any number), only one job -- often a different job -- gets filled.

Is that related to this code change?

===

If I don't favorite an empty job, this can leave me with unfilled jobs AND unemployed pops.

Then, a day or two later, all the pops move jobs -- including leaving jobs which had been filled -- which can leave me with shortages.

E.g. if I unlock 20 clerk jobs on a Ringworld to put 2 unemployed pops to work, then I've seen 18 farmers leave their farm jobs to become clerks the next day.

===

If these are related to this code change, then I'd suggest handling multi-job clicks differently.
Manually prioritizing a job will cause the job shifting update to be done the number of times as you had empty slots of that job. See the gif at the start of the video for an example.

This is to mimic the original behaviour of the job system to prevent mass panic. Humans like you and me do not enjoy mass panic.
 
  • 1Like
  • 1
  • 1Haha
Reactions:
Yes, and I have to use that mechanic when I unlock multiple jobs in one click.

Would it be possible to change the code to NOT require that extra micro when I unlock multiple jobs in one click?

Humans who click too much can receive injuries, because they are designed inefficiently and -- unlike a robot which I am definitely not -- a human can self-induce both frustration and injury using obvious robot-compatible mechanics like "just do more micro".


tl;dr - micro considered harmful for humans, which we definitely are.
I think my logic circuits have processed your communication protocol successfully now on the second iteration.

I didn't know that you could mass allow/forbid jobs via the shift clicking stuff. I will add it on my todobedo-list.
 
  • 10Like
Reactions:
Events related Fallen Empires (and the AI Rebellion) are pretty problematic, including the FEs getting destroyed by powerful AI empires fairly easily in the harder difficulties. Are there any plans to take a look at the big event chains like the AI rebellion, war in heaven, fallen empires in general etc. FEs at least could use some sort of difficulty based scaling so they would not be too easy to the players or the AI empires.

Also, huge thanks to @Offe for quick and multiple responses to the questions. And everyone else of course, too. :)
Unfortunately I can not give any good answer on that question, our primary focus has been on the normal AI empires and there are still so many areas left to improve. We have not yet discussed any plans for looking at fallen empires, but it is also sort of more in the realm of game design / content creation team and doesn't really fall purely under the AI umbrella so to speak.

We will continue to monitor what the effects are of the 3.3 AI reworks are and put our effort where we think we can get the most value, as always!
 
  • 5
  • 2Like
  • 2
Reactions:
Love seeing work being done on weights! That's been my personnel pet peeve. Looking forward to seeing what I can cross off my list!

I still think the best solution to the clerk problem is having them produce a small amount of admin cap unity.

If the AI can delete districts and stuff in order to replace them, does that mean it'll be able to build Resort Worlds or Thrall-Worlds now?
This list is truly something special :cool:
You should update this and verify for 3.3 status then repost it on the bug report forum and let's see what we can do about some of those. Several seemed pretty straight forward.

I made AI able to delete stuff in the easy case where they are superfluous. Them being able to replace things during a economic crisis is another beast of its own.

In the previous patch AI was given the ability to make ecumenopolis worlds by removing some of the requirements, with the new system they should be able to actually specialise planets to the degree that the prerequisites are fulfilled.

I'm not sure what sort of support we have for making AI use resort and thrall worlds. Probably things to look into once we run out of things to fix in the base economy o_O
 
  • 6Like
Reactions:
I think this explains a rather curious effect I noticed when upgrading my planetary capitals: there would always be an unemployed specialist pop after. I think something during that mass unassign then reassign would cause a worker pop to take a "vacant" specialist job and promote to a specialist pop, but then a leftover specialist pop would be out of a job at the end of the cycle.

Will this new method you're describing resolve that issue?

EDIT: Just wanted to add that the updates look awesome! Anything that makes the AI smarter and more challenging, especially in late game where it feels like your only real decision is "who do I want to steamroll first?".
Someone else mentioned this earlier as well so i will give them the same answer, try it on the open beta and if it is still bugged then post a save game and steps to reproduce on the bug forum and I will look
 
  • 2
  • 1Like
Reactions:
Definitely. I think this is the most interaction in a Dev Diary we've ever had, and on such an important topic as well, given how often we complain about the AI around here. This guy is absolutely assiduous! I'm yet to see a question go unanswered.

Thank you for showing great care towards your community. You rock!
There are some unanswered questions, but it is those which are completely offtopic from the DD itself, such as general game balance or such. I can't really help you guys out with those.
PS. Believe me there is no one who complains as much about the AI as I do, Guido can confirm :)
 
  • 8Like
  • 2Haha
Reactions:
A possible consideration: Make it possible for clerks to migrate, but at a much lower chance than unemployed pops (10% of base? 5%?). That way it serves like it did back when they were first added, as a sort of "buffer" job for extra pops. It'd still be unoptimal to keep pops as clerks, but only on a temporary basis, rather than a permanent one.
Could be on to something here
 
  • 11Like
  • 2
  • 1Love
  • 1
Reactions:
This all sounds great, I'm just wondering how often planetary designation calculations are performed? I'd imagine the weightings would change each time a tech that boosts a resource output is researched or pops with traits improving particular outputs arrive, but I'm concerned that might lead to the AI frequently either recalculating (which would hit performance) or redesignating (which would obviously hamper output), or alternatively sticking with one designation that becomes suboptimal over time.
I put it on the monthly update with a 1000 day cool down per planet.
 
  • 6
  • 1Like
Reactions:
While the AI and speed improvements overall do sound good and I do like the overall openness, I'm pretty alarmed to hear that you're revamping the jobs assignment logic without mention of the highly suboptimal assignments that often happen!

It's very easy to run into slaves or drone pops that are working the wrong job, and where a simple swapping of two pops' job would result in a +15% output increase.

It seems to that whatever arbitrary weight is assigned when a pop "desires" a job, especially if custom scripts are involved, shouldn't occult the actual output that will result. If worst comes to worst you could introduce a last pass after the selection of which pops will work to ensure they are placed in the slot that generates the most output: this pass would only allow swaps so wouldn't interfere with the prioritization of amenities or other needed resource. This would at least fix the scenario where pop A and B are both working jobs for which they're not particularly suited, and swapping them would at least cause one of them to benefit from some sort of bonus (+15% energy output for instance, like in the example in the thread linked above).

--

Side-note: as mentioned elsewhere I wonder if you've considered trading some extra memory for performance and pre-computing some values permanently for all existing race-job combinations. After all, once a race or job enters the game it never leaves, so the combinations created and associated values are good for the rest of the game. No point in computing them again every month. This lets you reuse the computation related to some never-changing facts (Robot race X has 15% energy production bonus) when computing values related to more dynamic elements (we're currently suffering a shortage of consumer goods).
So yes some pops work the "wrong" job in the sense that it would be possible to switch them around to minmax and get some more output, these issues are caused by the scripted weights. So the overall "rework" of the job assignment system will not make this better or worse as the problems still have to be fixed in the job weight scripts.

There was another user who posted a personal bug list with "easy to fix" bugs in the job weight scripts which seemed to be easy copy paste errors, so hopefully we can fix some of those. But again I want to reiterate that most of us developers do not sit and read these forums all day long, I am making an exception now since I wrote this DD and want to adress all the questions in here. But for the future I highly recommend posting the described issue with the combination of species/traits that cause this issue in a save game on the bug forum instead <3

About the side note, while what you say is true in principle, the scripted job weight system can be anything, such as changes in the galactic community or special buildings constructed on the planet or literally anything you can imagine. So while this would save some performance it would also limit what you would be able to do with the scripted job weights. Similar to the trade-off I made above which allows us to copy weights between pops of the same species.

Overall pop job weight calculations was a very small part of the overall game performance when I profiled it when I was making these changes. We are talking about something like a 1%~, and now it should be even less. Performance isn't something I have focused on for this patch, the primairy goal was to not make it any slower whilst still improving the experience.
 
  • 8
  • 2Like
Reactions:
have you considered making the AI "cheat" in a different way?
for example, setting the planet designation will swap 100% factory jobs to alloy and vice versa, there is no option to fine-tune it via a slider, i.e. 25% factory & 75% alloy
as a player i dont really care, besides the UI will be clunky with a slider
but the AI can have them, i dont mind, if it helps the AI make better decisions, i believe that would help make the transition into specialised factory/forge world smoother

in general, there are many aspects of the game where it will make sense to have the feature but its limited by UI, the AI can have them

another suggestion, under certain dire conditions, allow the AI access to special AI-only "IMF market" where it can make loans for resources and gain ability for instant build, they still need to pay off the loans

I sort of like this slider idea. But then it would have to be for both players and AI alike.
The easier and more obvious solution is to make the industrial district into a separate Alloy district and another Consumer Goods district.
We will never make a system for the AI which works fundamentally different from the player. The goal is to make the AI play the SAME game as the player, not a different one.
 
  • 6Like
  • 3
Reactions:
But you should have :( For me, this mod made is what makes the game playable in the first place. It already got AI economy and teching more than fixed, so looks like your work is cut out for you. Whatever that guy did - it just works. As much as I appreciate the notion of so-called free will and doing one's own thing, as a fellow Human you must understand the importance of submitting to superior solutions already in place, freeing the computational resource to advance the Cause in other areas.

As of now, with AI economy being fixed, the weakest point is AI military tactics, which in is neither modable nor ever mentioned in this article. This and diplomacy (who AI rivals and wars).

Also I don't see how any of this accounts for inter-state trade deals which, if played to the full of it, can relegate AI's to being mere raw recourse donors of player empire.
Most of the AI work has been done by fixing things in the code which mods can never change.
AI military tactics is high prio for future work!
 
  • 6Like
  • 2
  • 1Love
Reactions:
Love seeing work being done on weights! That's been my personnel pet peeve. Looking forward to seeing what I can cross off my list!

I still think the best solution to the clerk problem is having them produce a small amount of admin cap unity.

If the AI can delete districts and stuff in order to replace them, does that mean it'll be able to build Resort Worlds or Thrall-Worlds now?

I've just had a look at this list and made a number of fixes based off of it! Cheers.
 
  • 14Like
  • 9Love
Reactions:
You do realize this bug has been reported a long long time to the point PDX flags them as duplicates?!?!?!?!?!?




Have two to start your day.

Please just allow us to move pops to jobs freely. We are dealing with esoteric values as it is and there is little to no logic in this restriction being on the players. Where this restriction makes sense is the AI code not automatically demoting but instead flagging a pop to demote but allowing time for new pop growth to end the need
Cool can look at it

Edit: looked at the colony shelter and seems to work already
 
Last edited:
  • 1Like
  • 1
Reactions:
How is this requirement for 1+ biosanctuary per world handled? Is it just done through building files, or written in to the economic plan directly?

Just thinking about making a little test mod to force something like this but for different ethics
e.g. always at least 1 temple per spiritualist planet, 1 stronghold per militarist planet and so on
The solution for this problem was pretty roundabout due to there being an exploit prevention method inside the bio trophy job which prevents them from creating unity when their happiness is low, which prevents AI to be able to correctly estimate this job since the pop happiness is below this threshold when they are unemployed.

So I had to solve this using the ai_resource_production scripted trigger which I prefer not to use since it is basically telling the AI by hand crafted rules what something will do.

You can look at the bio sanctuary building script and see how it is done but it is not the easiest solution. Basically it checks if the building exists and then enable/disables the ai_resoruce_production to guide the AI into doing what we want
 
  • 3
Reactions: