Solid suggestion but one thing undermines it. Meta. Whatever AI will research, it won't matter much when players have meta templates with best division width and stuff.
Problem with these is, that they are to some degree interdependent. Especially 3 and 4. Shall we?
- Maintainability
- Going around the problem instead of through it (though, there is nothing inherently bad in this approach)
- Narrow-band solution, providing only for a set parameter of circumstances. Once you leave these circumstances, the thing breaks completely
- Exploitability
What happens when the AI is "stronger" is that people complain that the mechanics are broken instead.
Remember for example when the launch AI port striked all poor players German starting fleet into oblivion? Mechanics were changed so it's no longer possible to do ( and the mechanics were changed in a rushed hacky bad kind of way as well with a hard blocker to port strikes which is just bad ).
That has less to do with "strong AI" and more to do with the function/ability of port strikes being imbalanced to the overall gameplay. You even state it yourself, the "mechanics were changed" as being the primary factor here, not the AI that was changed. Obviously the AI might have been changed, but it was the effectiveness of the port strike missions that was the problem, not the AI's determinations on when and where to use them.
On the discussion of AI and scripting in general, people should be aware that all AI is scripted.
I think it is fairly well accepted at this point that the AI would do better in its production and research etc. if some of its tendencies were scripted. I think there is no strong argument in favor of the current one size fits all approach to such things.
The Devs strongest and almost only argument against that is their perception that a scripted AI is more predictable and therefor in the long run a less challenging opponent.
The solution seems relatively obvious. For each of the majors make 4 or 5 scripts for an overall production and research strategy (including some template preferences). Have the AI choose one semi-randomly at the start of the game. I say semi-random since some would have a higher weight and be more likely to be chosen than others.
The other argument against is the time it would take. In my opinion this would not take as long as many other changes would. It is also not the highly difficult type of AI programming and would likely not even require @SteelVolt 's direct attention.
You could take that a step further by making say 3 scripts for the minors and depending on the nature of the country assign them to one or the other (no randomness). Countries like China for example should be taking a far different approach to their overall scheme than should a country like Hungary.
Just quickly:On the discussion of AI and scripting in general, people should be aware that all AI is scripted. Data IN > Process > Data OUT > Determination. So really this discussion is semantics and degrees of flexibility to various aspects of the logic/formula behind the AI.
Its decisions are all based in the current situation.
I do hope that I stay on topic ;-)Instead of directly quoting any individuals at this point, I will reply in general. I do this because less than half the thread is on topic and what is managing to stick to the subject seems to share a theme.
True enough. My personal reservations against a band-aid via scripting are that those things have the tendency to become fixtures. I am supported by this by a bit of computer-science/programming literature (f. ex. Clean Code [the one with the galaxy on the cover]). If you introduce something, make sure you can build on it. Else, throwing it out will be a fight. And yes, I am arguing to authority here.To paraphrase the main objection to having each major use targeted scripting in support of a high level strategy, it seems to be, "What if this sets the course of the AI upon a bad path?"
My response in a nutshell is one of my favorite quotes from Teddy Roosevelt, "In any moment of decision the best thing one can do is the right thing, next best is the wrong thing, the worst is nothing."
Yes, this is something I agree on. Although, I would first recheck the focus trees and their handling, since those are imho the "driver" for the game.Right now the AI drifts more or less aimlessly with no real plan at all. Its strategy is whatever the NFs tell it to be for the moment. I suppose that is better than nothing at all, but its approach is certainly not integrated. One of the biggest conceptual flaws to the processes used by the AI is that it lacks a sense of future. Its decisions are all based in the current situation. Having overarching scripts for those limited areas to which I referred; research, production and templates; would at least give it some sense of direction. This would be much more efficient than how it currently handles things.
Thing is, you could simply add weight to the relevant AI subroutines. Problem is, they don't work. Currently. I'd take this opportunity again to pitch the suggestion of reducing the amount of input. The grumbling introduction of impassable borders is a step into this direction.It seems completely obvious that this has to be done separately for each major nation. Japan has a greater need to research naval advancements than does Germany, for example. How does one get the AI to play effectively without tailoring tendencies? One could argue that if the AI is smart enough and takes enough factors into consideration, then it will come to the right conclusions regardless of which country it is controlling. That philosophy requires technology beyond what we have on our desks and programming which is beyond the capabilities of Paradox. They have neither the manpower nor the capital to produce something so complete. Individually scripting research tendencies is well within the scope of this project and their capabilities.
As has been pointed out in this thread, the issue isn't that it doesn't solve the problem. The issue is that it is hard to change (that includes removal. Have you ever put of work for so long that at the end it became the mountain of doom?) afterwards.Would this approach produce a perfect AI? Of course not, but then neither will the current course of action that they are following. Would my suggestion produce a significantly better AI? I firmly believe that it would.
True enough. My personal reservations against a band-aid via scripting are that those things have the tendency to become fixtures. I am supported by this by a bit of computer-science/programming literature (f. ex. Clean Code [the one with the galaxy on the cover]). If you introduce something, make sure you can build on it. Else, throwing it out will be a fight. And yes, I am arguing to authority here.
As has been pointed out in this thread, the issue isn't that it doesn't solve the problem. The issue is that it is hard to change (that includes removal. Have you ever put of work for so long that at the end it became the mountain of doom?) afterwards.
Programmers often are reluctant to introduce that kind of stuff, if they are good. I think the problem in this case is a disconnect between the thinking of programmers/developers and non-devs. It kinda makes these kind of things hard to explain because they rely on a lot of implicit knowledge and experience. Now that I think about it, you could construe software and hardware as some kind of mystery cult. Long live the byte, as it is revealed to us!
May I ask how much programming experience do you have, Dalwin?
Edit: I ask because that isn't tattoded on your forehead (on the forums) and you demostrate competence and well-reasoned arguments (and yes, I am really bad at these "social interaction" things).
Point. In this case, I see no further point in arguing this considering your greater amount of experience. Although I'll maintain my stance of cautioning against simply scripting it wholesale. Why is the script of fourth semester software engineering "team roles" flashing before my eyes?I do not disagree with the basis of this argument, not even a little. I do, however, disagree with your conclusion and interpretation of where this tendency takes us in the future.
External/internal POV perhaps? Idk. And honestly, I do not feel qualified to render judgement on this, given my lack of information..Yes, anything seen as an interim solution, or bandaid in the common vernacular, runs a risk of becoming a permanent fixture. I have already successfully pushed for one of those early in the game and the community successfully did again just now in the Sahara.
Don't take me there. I've had some bad experiences in both directions with "it's attainable" and "that's too much effort". Unfortunately this was in the course of working for a person who rapidly oscillated between these positions. *gah* Further, the focus on the thing shifted from week to week, and I forgot to take notes (and was far too intimidated by the guy). Oh well, lessons learned.Before deciding if that is a risk worth taking or if it is even really a risk at all one must ask one question. Is their currently stated plan at all realistic? Is their a significant likelihood that they will succeed in the next six months or even in the next two years? My opinion is emphatically that I believe they will not. The AI, in HOI4, will never reach the lofty plateau set by their current design philosophy. Perhaps in HOI5 but not in 4. My suggestion is realistic and attainable even if it is less satisfying for @podcat and company on a philosophical level.
My first programming classes were in 1976. I have no degree in the field and my only professional experience is to have developed some business applications using visual basic. I do, however, have some experience in project management and I think there is a fair amount of overlap in this context.
By the time you are doing "different weights per country," You are already on board with what I am seeking. The important part is not the semantics of how the pieces are labeled. Nor is it one of the degree of separation between the pieces when it comes to different nations. The main point, in my eyes, is that they need to recognize from day one that the different nations should be taking different approaches to strengthening their positions and achieving their goals. Just the simple tendency at the moment of every AI driven nation from Germany to France to China to Peru to strive for nearly identical 7+2 infantry templates even if producing those is unrealistic for many nations, points to the serious need for more customization.I don't think that the scripting is necessarily that straightforward or potentially less effort than just small basic research and production algorithms that could have weights per country. As permanently_afk points out, there are also some drawbacks especially around maintenance if you do it by country.
I think the better solution would be to evaluate the research and production of the major nations in the current version. Determine what they do poorly and determine at least a base algorithm that could handle it well. In comparison to army management, research and production are way easier to have the AI do decently.
By the time you are doing "different weights per country," You are already on board with what I am seeking. The important part is not the semantics of how the pieces are labeled. Nor is it one of the degree of separation between the pieces when it comes to different nations. The main point, in my eyes, is that they need to recognize from day one that the different nations should be taking different approaches to strengthening their positions and achieving their goals. Just the simple tendency at the moment of every AI driven nation from Germany to France to China to Peru to strive for nearly identical 7+2 infantry templates even if producing those is unrealistic for many nations, points to the serious need for more customization.
Am I missing something or isn't this already done in common/ai_strategy/<country>.txt? (To some degree at least)By the time you are doing "different weights per country," You are already on board with what I am seeking
They have paid a bit of lip service to it, though it is my understanding that is mostly concerned with evaluating the importance to different theaters. I do not think it does much with research priorities, or production decisions, or template preferences. Now I realize that I am getting repetitive with those three items, but by now some might have noticed that those are also the most central things focused on by mods such as Expert AI 2.0.Am I missing something or isn't this already done in common/ai_strategy/<country>.txt? (To some degree at least)