AI

A secret place for modders to chat and ask questions. Requires forum registration.

Moderators: firepowerjohan, Happycat, rkr1958, Slitherine Core

Post Reply
peterjfrigate
Sergeant First Class - Panzer IIIL
Sergeant First Class - Panzer IIIL
Posts: 365
Joined: Mon Aug 16, 2010 12:43 am

AI

Post by peterjfrigate »

Is there a mod that allows you to assign some of the nations on your side to computer control (e.g. to let the AI control Russia when you are the Allies, etc)?

I'd also be interested in knowing if it's possible for players to mod the AI.
BuddyGrant
Sergeant - 7.5 cm FK 16 nA
Sergeant - 7.5 cm FK 16 nA
Posts: 225
Joined: Sat Apr 11, 2009 7:06 am

Re: AI

Post by BuddyGrant »

peterjfrigate wrote:Is there a mod that allows you to assign some of the nations on your side to computer control (e.g. to let the AI control Russia when you are the Allies, etc)?
Nope.
peterjfrigate wrote:I'd also be interested in knowing if it's possible for players to mod the AI.
You can edit some stuff that alters the AI's logic. For example, in the vanilla game or in the 'Grand Strategy' add-on the Allied AI in the Med and North Africa will generally just sit there. If the AI believes it has enough units and PP's for the defense of the UK then it will actually send units via transport through the Med to reinforce the Suez Canal zone or make a beach landings in Axis occupied North Africa. That means that editing the at-start UK forces will impact how the AI deals with the Med.

There are probably other examples like this, but this is the only one I am certain about. There also appear to be some AI related options in the 'GENERAL.TXT' file, but I have not experimented with them at all and would assume they are pretty limited in impact.
blackcross
Lance Corporal - Panzer IA
Lance Corporal - Panzer IA
Posts: 15
Joined: Fri Jan 21, 2011 9:45 am

Post by blackcross »

i am currently working on a patch and have done some interesting things with ai
Hammer4000
Sergeant - 7.5 cm FK 16 nA
Sergeant - 7.5 cm FK 16 nA
Posts: 226
Joined: Tue Sep 07, 2010 5:48 am
Location: Ohio,USA

Post by Hammer4000 »

so hows that patch goin, (if you havent gave up) i'de like to see what kinda things canb be done with the AI
pzgndr
Senior Corporal - Ju 87G
Senior Corporal - Ju 87G
Posts: 79
Joined: Fri Jun 03, 2011 11:12 am

Post by pzgndr »

I understand nothing has been done with the AI for GS 2.0. I'm taking another look after a couple years at CEAW with this new mod and wondering what could be done with the latest general.txt file. Seems there are a lot of new capabilities for optimizing the game for either Axis or Allied AI. :?:

1. Does the AI still not buy/deploy/use leaders? Then deleting the free commanders could help provide some play balance versus the computer opponent.

2. Can the Spawned Units Rules be used to add units to compensate for AI weaknesses? For example, additional Axis or Allied deployments to North Africa to make up for no/limited transport scripting, or extra units for Barbarossa or D-Day or whatever, etc. Some guidance for editing general.txt would be helpful. Is it possible to set spawned units for only the AI side, or would separate general.txt files be needed for playing either Axis or Allied side?

3. The AI rules appear to provide some flexibility for capital_defence, defence_reaction, and safe_air_distance. What are the pros/cons for adjusting these? Again, some guidance would be helpful.
rkr1958
General - Elite King Tiger
General - Elite King Tiger
Posts: 4264
Joined: Wed Dec 12, 2007 2:20 am

Post by rkr1958 »

pzgndr wrote:I understand nothing has been done with the AI for GS 2.0. I'm taking another look after a couple years at CEAW with this new mod and wondering what could be done with the latest general.txt file. Seems there are a lot of new capabilities for optimizing the game for either Axis or Allied AI. :?:

1. Does the AI still not buy/deploy/use leaders? Then deleting the free commanders could help provide some play balance versus the computer opponent.

2. Can the Spawned Units Rules be used to add units to compensate for AI weaknesses? For example, additional Axis or Allied deployments to North Africa to make up for no/limited transport scripting, or extra units for Barbarossa or D-Day or whatever, etc. Some guidance for editing general.txt would be helpful. Is it possible to set spawned units for only the AI side, or would separate general.txt files be needed for playing either Axis or Allied side?

3. The AI rules appear to provide some flexibility for capital_defence, defence_reaction, and safe_air_distance. What are the pros/cons for adjusting these? Again, some guidance would be helpful.
To be honest zero focus was put on the AI. All effort went to improving the historical feel and balancing the game for human-to-human play (either PBEM or hotseat).
pzgndr
Senior Corporal - Ju 87G
Senior Corporal - Ju 87G
Posts: 79
Joined: Fri Jun 03, 2011 11:12 am

Post by pzgndr »

I got that. Answers to my other questions please?
Peter Stauffenberg
General - Carrier
General - Carrier
Posts: 4745
Joined: Sun Jul 08, 2007 4:13 pm
Location: Oslo, Norway

Post by Peter Stauffenberg »

I don't think any of these questions have anything to do with general.txt. It's about the AI code in CeaW. We've not altered the AI code at all and not tested how it works. I haven't played an AI game for years and don't know if the AI allocates free leaders or not. Probably not.

So to deal with this you need to make code to force the AI to place leaders, but they will not use them wisely like maintaining optimal distance to cover enough units etc.

Changing the AI code is a huge amount of work because there are so many things you need to look at that could have been improved. This is something we decided not to do because AI coding was not within our scope. We don't play against the AI when we have real players to play against.

What needs to be done is to actually try to create a challenging game against the AI and that can be done by having separate scenarios where the AI starts with more units. I'm not sure what is the right adjustment.

To make the AI use the amphs or paras then code needs to be added. That has to be done by someone else. If someone with good Java skills wants to do that then he can contact us and we can add him to the developer group. But until that happens then we won't do anything with the AI.

Changing general.txt won't have that big effect. The values in the AI section was made for the vanilla game and I don't know how changing them will affect the AI behavior. Trial and error is probably the way to do it.
pzgndr
Senior Corporal - Ju 87G
Senior Corporal - Ju 87G
Posts: 79
Joined: Fri Jun 03, 2011 11:12 am

Post by pzgndr »

Thanks for responding! I am not asking about changing AI code. That's a whole other can of worms.

Given the AI as-is and the general.txt file, what can modders do? As I mentioned, if AI does not use leaders then there's no point further handicapping it by using leaders. So all those free leader arrivals in general.txt could be removed. Players could still buy them.
What needs to be done is to actually try to create a challenging game against the AI and that can be done by having separate scenarios where the AI starts with more units. I'm not sure what is the right adjustment.
Spawning units is also obviously possible but there is no guidance for how to do edit the general.txt file to spawn additional units later in scenarios. In lieu of trial and error, how about some explanations for how to do this? Modders can then experiment with separate scenarios and separate general.txt files as necessary. There are possibilities here.
Peter Stauffenberg
General - Carrier
General - Carrier
Posts: 4745
Joined: Sun Jul 08, 2007 4:13 pm
Location: Oslo, Norway

Post by Peter Stauffenberg »

Remember that the free leaders won't all spawn (except the 1944 scenario). Only one leader per country will spawn if you start the 1939 scenario. I don't think that will affect the outcome very much.
rkr1958
General - Elite King Tiger
General - Elite King Tiger
Posts: 4264
Joined: Wed Dec 12, 2007 2:20 am

Post by rkr1958 »

pzgndr wrote:Given the AI as-is and the general.txt file, what can modders do? As I mentioned, if AI does not use leaders then there's no point further handicapping it by using leaders. So all those free leader arrivals in general.txt could be removed. Players could still buy them.
The AI will deploy free leaders given to it at the beginning of a scenario. It will; however, not build additional leaders.
pzgndr
Senior Corporal - Ju 87G
Senior Corporal - Ju 87G
Posts: 79
Joined: Fri Jun 03, 2011 11:12 am

Post by pzgndr »

Remember that the free leaders won't all spawn (except the 1944 scenario). Only one leader per country will spawn if you start the 1939 scenario. ... The AI will deploy free leaders given to it at the beginning of a scenario.
Well, then I don't understand the Free Commanders list with more than one leader per country. See, this is stuff where another comment line in the file would be helpful. I assumed all those leaders get spawned in the years indicated; Guderian 1941, Manstein 1941, Rommel 1942, etc. So, only one gets spawned, or what? :?

And if AI does deploy leaders then it may be fair to keep them in the spawned unit list. That's worth checking out.
I don't think that will affect the outcome very much.
Perhaps not. But half the fun with modding is the journey, not the destination. :wink:
Peter Stauffenberg
General - Carrier
General - Carrier
Posts: 4745
Joined: Sun Jul 08, 2007 4:13 pm
Location: Oslo, Norway

Post by Peter Stauffenberg »

The year behind the leader shows which scenarios or later the leader will spawn in. So a 1939 leader will always spawn. A 1942 leader will only spawn in the 1942, 1943 and 1944 scenarios and so on.
Post Reply

Return to “Commander - Europe at War : Modders Corner”