• 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.

Maximilian I

Bierbrauer
61 Badges
Oct 18, 2000
9.271
0
forum.paradoxplaza.com
  • Hearts of Iron II: Armageddon
  • Victoria 2: A House Divided
  • Sengoku
  • The Kings Crusade
  • Impire
  • Hearts of Iron III
  • Stellaris - Path to Destruction bundle
  • Europa Universalis III Complete
  • Darkest Hour
  • A Game of Dwarves
  • Crusader Kings II
  • Hearts of Iron IV: Together for Victory
  • Stellaris: Ancient Relics
  • Steel Division: Normandy 44
  • Europa Universalis IV: Mandate of Heaven
  • Knights of Honor
  • BATTLETECH
  • Hearts of Iron IV: Death or Dishonor
  • Stellaris: Leviathans Story Pack
  • Stellaris: Synthetic Dawn
  • Age of Wonders III
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Humanoids Species Pack
  • Europa Universalis 4: Emperor
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Distant Stars
  • Europa Universalis IV: Dharma
  • Crusader Kings III
  • Imperator: Rome
  • Age of Wonders: Planetfall Season pass
  • Age of Wonders: Planetfall - Revelations
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis III Complete
  • Europa Universalis III Complete
  • Stellaris: Federations
  • Victoria 2
  • Hearts of Iron IV: La Resistance
  • Tyranny: Archon Edition
  • Hearts of Iron IV: No Step Back
  • 500k Club
  • Age of Wonders: Planetfall
  • Hearts of Iron II: Beta
  • Crusader Kings II: Way of Life
  • Europa Universalis IV: Common Sense
  • Stellaris
  • Hearts of Iron IV: Cadet
The thread to discuss and debate the various AI files for National (and Communist) China
 

unmerged(14753)

Second Lieutenant
Feb 14, 2003
160
0
Visit site
Ok I was going to post the china.ai file I am currently using but I am theorizing that if used against the current japan.ai file, China will "own" Japan. Im going to install my china.ai file into vanilla 1.05 and see if this is true. In my modded 1.05, I have improved the japan.ai to be more effective by amphibbing (is that a real word? :D ) Shanghai and Nantong, and the South China beaches which forces china.ai to spread its troops all over the place... and if you look at real life historical maps this is what Japan did. Even so, my improved china.ai can hold out as long as late 1941 without any help.

Another snag with the whole Japan vs. China situation is, I want to have UK and USA help China early by sending them rubber, oil, and supplies. However, I haven't been able to justify this to myself because all historical records I have read show that no one really helped China until about 1942 or so. If I am wrong about this I'd love to hear about it.

In any case... China can't survive vs. Japan like it did in real history without at least some resource help from other nations... unless japan.ai is nerfed into stupidity.

Last thing: what I'd really like to do when I start posting my ai files is to post a HoI map under it with John Madden (a famous american football announcer) like markings on it showing what the ai is trying to do. :D The only problem is I don't understand how you add images to posts... could someone explain this to me? Also I don't want to pay money to be able to do this. :D
 

Steel

Field Marshal
56 Badges
May 4, 2001
7.689
0
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Mare Nostrum
  • Stellaris
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Hearts of Iron IV: Cadet
  • Europa Universalis IV: Rights of Man
  • Tyranny: Archon Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Hearts of Iron IV: Together for Victory
  • Pillars of Eternity
  • Steel Division: Normandy 44
  • Europa Universalis IV: Mandate of Heaven
  • Steel Division: Normandy 44 Deluxe Edition
  • Europa Universalis IV: Third Rome
  • BATTLETECH
  • Hearts of Iron IV: Death or Dishonor
  • Age of Wonders III
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Imperator: Rome - Magna Graecia
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Crusader Kings II
  • Hearts of Iron III
  • Majesty 2
  • Europa Universalis IV: Res Publica
  • Victoria 2
  • 500k Club
  • Cities: Skylines
  • Cities: Skylines Deluxe Edition
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Pre-order
  • Hearts of Iron II: Beta
IMHO China has enough forces. The main issue is how to deploy them and historically this was highly regional as different warlords controlled different regions. This can be simulated by setting high min/max_garrison settings. As the Japanese advance, the relative strength of each garrison province is increased while keeping the forces out of the Front AI's control.
 

Vulture

Aerandir Eärfalas
42 Badges
Mar 20, 2001
31.960
0
www.europa-universalis.com
  • Crusader Kings II
  • Europa Universalis IV: Third Rome
  • Hearts of Iron II: Beta
  • Europa Universalis IV: Pre-order
  • 500k Club
  • Hearts of Iron II: Armageddon
  • Semper Fi
  • Europa Universalis: Rome
  • Europa Universalis IV: Res Publica
  • Europa Universalis III Complete
  • Europa Universalis III Complete
  • Hearts of Iron III
  • For the Motherland
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Heir to the Throne
  • Europa Universalis IV
  • Divine Wind
  • Europa Universalis III
  • Hearts of Iron IV: Together for Victory
  • Europa Universalis IV: Mandate of Heaven
  • Europa Universalis 4: Emperor
  • Hearts of Iron IV: Death or Dishonor
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Europa Universalis IV: Rule Britannia
  • Europa Universalis IV: Dharma
  • Europa Universalis IV: Golden Century
  • Crusader Kings III
  • Europa Universalis IV: Rights of Man
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Common Sense
  • Europa Universalis: Rome Collectors Edition
  • Europa Universalis III: Collection
  • 200k Club
  • Rome: Vae Victis
  • Europa Universalis IV: El Dorado
Originally posted by Steel
IMHO China has enough forces. The main issue is how to deploy them and historically this was highly regional as different warlords controlled different regions. This can be simulated by setting high min/max_garrison settings. As the Japanese advance, the relative strength of each garrison province is increased while keeping the forces out of the Front AI's control.

I tend to agree... Although, I can say the Chinese hold out fairly well with the current patch. Fact is the Chinese should behave similarly to the USSR... They ought to struggle very hard in the beginning, losing ground enormously. In the end they should be winning though, not the other way round
 

unmerged(14393)

General
Feb 4, 2003
1.768
0
Visit site
"Last thing: what I'd really like to do when I start posting my ai files is to post a HoI map under it with John Madden (a famous american football announcer) like markings on it showing what the ai is trying to do. The only problem is I don't understand how you add images to posts... could someone explain this to me? Also I don't want to pay money to be able to do this. "

*Lol*...you rock, Roxxor! And after all...sports is the modern equivalent to war.

I´ve been reading your posts here, and they seem very promising indeed. I can´t wait to try them out!

As for China and the shipments of resources to them: Okay, maybe no one supported them before 1942, but if other nations start supporting them early on that is in my book less historically accurate than China, large as it is, losing a war against Japan.
 

unmerged(14753)

Second Lieutenant
Feb 14, 2003
160
0
Visit site
Just did a handsoff with my modded china.ai file inserted into vanilla 1.05.... they weren't annexed until July 1942. Pretty good and clearly better than the vanilla china.ai file but not quite the "ownage" I anticipated.

So... back to the drawing board for china.ai for me :D
 

Vulture

Aerandir Eärfalas
42 Badges
Mar 20, 2001
31.960
0
www.europa-universalis.com
  • Crusader Kings II
  • Europa Universalis IV: Third Rome
  • Hearts of Iron II: Beta
  • Europa Universalis IV: Pre-order
  • 500k Club
  • Hearts of Iron II: Armageddon
  • Semper Fi
  • Europa Universalis: Rome
  • Europa Universalis IV: Res Publica
  • Europa Universalis III Complete
  • Europa Universalis III Complete
  • Hearts of Iron III
  • For the Motherland
  • Europa Universalis IV: Call to arms event
  • Europa Universalis IV: Wealth of Nations
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Art of War
  • Heir to the Throne
  • Europa Universalis IV
  • Divine Wind
  • Europa Universalis III
  • Hearts of Iron IV: Together for Victory
  • Europa Universalis IV: Mandate of Heaven
  • Europa Universalis 4: Emperor
  • Hearts of Iron IV: Death or Dishonor
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Europa Universalis IV: Rule Britannia
  • Europa Universalis IV: Dharma
  • Europa Universalis IV: Golden Century
  • Crusader Kings III
  • Europa Universalis IV: Rights of Man
  • Hearts of Iron IV: Colonel
  • Hearts of Iron IV: Cadet
  • Europa Universalis IV: Mare Nostrum
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Common Sense
  • Europa Universalis: Rome Collectors Edition
  • Europa Universalis III: Collection
  • 200k Club
  • Rome: Vae Victis
  • Europa Universalis IV: El Dorado
What was the result of the prolonged Chinese existance vis-a-vis the Japanese performance. It has dawned to me, that the more difficult it is for the Japanese to kill NatChi, the less troops they dedicate (if any at all) to overseas invasions
 

unmerged(14753)

Second Lieutenant
Feb 14, 2003
160
0
Visit site
Ok Im finally happy with my china.ai file. This one puts up stiff resistance to Japan and builds more troops. I've had handsoff games where NatChina lasts the entire war in a good position. Here it is:

#
# file: china.ai
#
# Hearts of Iron
#
# By Trip (modified by Roxxor)
#
# Standard China AI file
#

# 100 = Total warmonger, 0 = absolute pacifist

war = 50

max_garrison_prop = 0.4
min_garrison_prop = 0.3
strat_redeploy_threshold = 15

influence = {
CHC INO MAN SIA SIK TIB USA
}

construction = {

max_factor = 0.0

AA_batteries = no

coastal_fort = no
}

military = {

relative_build_scheme = no

infantry = 70
cavalry = 11
motorized = 0
mechanized = 0
panzer = 5
paratrooper = 0
marine = 0
bergsjaeger = 0
# 86 %
fighter = 6
strategic_bomber = 0
tactical_bomber = 4
naval_bomber = 2
dive_bomber = 2
transport_plane = 0
torpedo_plane = 0
# 14 %
battleship = 0
carrier = 0
destroyer = 0
cruiser = 0
submarine = 0
transports = 0
# 0 %
}

technology = {

endgoal = {}
preference = {1202 1204 14008 14009}

electronics = 0.0
armor = 0.0
infantry = 2.0
industry = 0.0
rocket = 0.0
nuclear = 0.0
heavy_aircraft = 0.0
light_aircraft = 0.0
naval = 0.0
submarine = 0.0
artillery = 2.0
naval_doctrine = 0.0
land_doctrine = 0.0
air_doctrine = 0.0
}

garrison = {

defend_overseas_beaches = no

# PRIORITIES:
beach_1 = 50 # Beach level 1
beach_2 = 55 # Beach level 2
beach_3 = 60 # Beach level 3
capital = 100 # Our capital
human_border = 100 # Ignored for allied human players
war_target = 100 # The next country targeted for attack by this AI

opposing_alliance = 0 # For neutrals, all alliances are "opposing"
claim_threat = 0 # If we are neutral, countries with claims on us get this
unstable_border = 50 # Bordering countries at war with someone else get this

# Borders with specific countries
country_priorities = {
ENG = -1
SOV = -1
MON = -1
TRK = -1
FRA = -1
TIB = -1
NEP = -1
SIK = -1
CHC = 50
JAP = 800
}
# Specific provinces
province_priorities = {
1701 = 50 # Jiangmen
}

key_point_prio_mult = 0
}

front = {
recklessness = 0 # 0-3
enemy_reinf_days = 2
reserve_prop = 0.3
panic_ratio_vs_ai = 2.000
panic_ratio_vs_human = 2.000
base_attack_odds = 3.000
min_attack_odds = 2.000
max_attack_odds = 4.000
reinforce_odds = 1.500
withdraw_odds = 1.000
distrib_vs_ai = even
distrib_vs_human = even
}

Some quick comments:

Construction: why? it makes china build less industry for Japan and more troops.

Technology: Tired of seeing china build all tank technologies but never a actually usuable tank. At least this way they get a few useful applications. However I admit this area could be improved.

Garrison: The 800 vs. Japan makes a big difference. Why Jiangmen? its a crucial defensive province that blocks Japan from advancing from a southern beach invasion and a northern one too. Really slows Japan down in southern amphibs.

Front: I don't know for sure if its doing anything but after watching china's nice moves I'm thinking setting enemy_reinforcement_days to a low value is good for land based defensive ai's (note this is set to 2).
 

Steel

Field Marshal
56 Badges
May 4, 2001
7.689
0
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Mare Nostrum
  • Stellaris
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Hearts of Iron IV: Cadet
  • Europa Universalis IV: Rights of Man
  • Tyranny: Archon Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Hearts of Iron IV: Together for Victory
  • Pillars of Eternity
  • Steel Division: Normandy 44
  • Europa Universalis IV: Mandate of Heaven
  • Steel Division: Normandy 44 Deluxe Edition
  • Europa Universalis IV: Third Rome
  • BATTLETECH
  • Hearts of Iron IV: Death or Dishonor
  • Age of Wonders III
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Imperator: Rome - Magna Graecia
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Crusader Kings II
  • Hearts of Iron III
  • Majesty 2
  • Europa Universalis IV: Res Publica
  • Victoria 2
  • 500k Club
  • Cities: Skylines
  • Cities: Skylines Deluxe Edition
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Pre-order
  • Hearts of Iron II: Beta
IMHO you are making a mistake with the construction. You are ensuring that China will never build up their numerous low-IC areas (high ROI) and never build AA (very high ROI). This will cut deeply into long-term viability of western China and the AI will be struggling to meet supply requirements.

Since you have no air tech research at all I recommend you also remove construction of air units. The pre-war aircraft will never achieve anything against the Japanese air force and navy, but they will be a serious drain on supplies and possibly oil.

You may want to place some garrisons farther west. Deploying almost the entire army on the north China frontier is ahistorical as well as dangerous since it invites encirclement. Keeping at least a minimum force at the border with Indochina prevents a sudden Japanese invasion from the south in 1940. Getting at least 1-2 divisions in key mountain provinces tends to slow down the Japanese advance.

I'd recommend an admiral section as well, China does have a borderline viable navy although the AI usually sacrifices it at Shanghai. Get them to deploy in the west, near Indochina, where the Japanese fleet is unlikely to mass in great force.

Finally you may want to look at handicap and passivity against CHC, SIK and JAP.
 

unmerged(14856)

First Lieutenant
Feb 18, 2003
234
0
Visit site
Comments:
  • strat_redeploy_threshold = 15
    Shouldn't this be increased? To prevent the ai from strategic move troops without org to the front?
    I'd like this value to be at least 20-30.
  • influence = {CHC INO MAN SIA SIK TIB USA}
    Negotiate with the most hated enemy the CHC? Never I say. We will squash them like a bug.
    Indonesia, why? It's not like we have those DI in abundance you know.
    Manchuria, I'm afraid they are lost, they where a carefully selected sacrifice.
    When it comes to Sinkiang it's them trying to talk to us not the other way around. The only diplomatic contact we would consider would be a declaration of war.
    Tibet? Why send diplomats to the monks, they don't listen anyway...

    No let our best diplomats do something useful:
    influence = { USA SIA JAP }
    Siam is the only neighbour we can trust.
    USA are the only western power that seem friendly. It can also keep those evil british at bay.
    And we must restore relations with those dreaded Japanese so that they won't do anything stupid.
  • Our wartargets are missing.
    After we have reunited our great nation we should put things back to order as well.
    combat = { CHC SIK }
  • construction ai
    You have seem to forgotten the words of Kon-Fu tse. The future trusts in the past to save it.
    When at peace we should prepare the country for the future.
    Code:
    construction = {	#During periods of peace we will prepare for war.
    max_factor   = 0.2  #Max 20%
    max_AA    = 4	    
    AA_batteries   = not_atwar	
    max_AA_level  = 1    
    coastal_fort   = no
    ic_at_war   = no   
    force_ic_until  = 1938	#Build IC for two years this will improve most of our 1IC provinces   
    ic_end_year   = 1942	#By then it should be enough    
    }
  • military ai
    Lots of problems here. Our Panzers are as slow as our cavalry, and since we can't afford to upgrade them they will be useless.
    With our tech dive bombers are as effective as tactical bombers but costs less. The same goes for torpedo vs naval.
    These are my humble suggestions:
    Code:
    military = {
    	relative_build_scheme 	= no
    	
    	infantry = 		60
    	cavalry = 		11
    	motorized = 		11	#We can convert our coal to oil
    	mechanized =		0
    	panzer = 		0	#Can't afford the research nor the production cost
    	paratrooper = 		0
    	marine = 		0
    	bergsjaeger = 		1	#For fun and half our country is mountains
    #					83 %
    	fighter = 		5
    	strategic_bomber = 	1	#For the suprise factor
    	tactical_bomber = 	1	#Slim chance but for historical reasons it should be here
    	naval_bomber = 		1	#Slim chance but for historical reasons it should be here
    	dive_bomber = 		5	#The most effective bomber without spending the tech
    	transport_plane = 	0 
    	torpedo_plane = 	2	#Much better bang for bucks than Naval
    #					15 %
    	battleship = 		0
    	carrier = 		0
    	destroyer = 		1	#Slim chance but for historical reasons it should be here
    	cruiser = 		1	#Slim chance but for historical reasons it should be here
    	submarine = 		0
    	transports = 		0
    #					2 %
    }
  • technology ai

    Code:
    technology = {
    
    endgoal = {}
    preference = {1202 1204 14008 14009}
    
    electronics = 		0.001	#Minimum for historical reasons
    armor = 		0
    infantry = 		4.0	#Higher then artillery for the AI to prioritize this
    industry = 		0.001	#Minimum for historical reasons
    rocket = 		0
    nuclear = 		0
    heavy_aircraft = 	0.001	#Minimum for historical reasons
    light_aircraft = 	0.001	#Minimum for historical reasons
    naval = 		0.001	#Minimum for historical reasons
    submarine = 		0.001	#Minimum for historical reasons
    artillery = 		3.0
    naval_doctrine = 	0.001	#Minimum for historical reasons
    land_doctrine = 	0.1	#They should at least try to get one or two
    air_doctrine = 		0.001	#Minimum for historical reasons
    }
  • garrison ai
    As discussed elsewhere human_border should be 0 so that if I play the UK the ai wont defend against me instead of the Japs.
    I'd also like to see key_point_prio_mult set to 1 so that the ai would prefer them to non key point provinces.
    Other than that I really like your garrison ai =)
  • front ai
    Why is your enemy_reinf_days set so low? This helps the ai calculate on where it's enemies troops are heading. Without this he won't defend provinces which his enemies are about to attack. For a country with such huge provinces it should be set to 30.

  • No bomber ai?
  • No admiral ai?
    Should either defend 'Bobai Sea' or 'Shanghai Sea'.
 

unmerged(14753)

Second Lieutenant
Feb 14, 2003
160
0
Visit site
Spoonist and Steel, thanks for the replies...

Here's the metric I'm using for which ai file is better to use:

Which ai file survives the longest vs. Japan (ai Japan)? The one that survives the longest is the best. Why? because that's what happened historically and makes for a funner game when the axis is having problems instead of conquering the world by 1943-44.

If you disagree with what I said above, that's fine. My problem with all of your suggestions is that I've tried doing what you suggest and the result is always that China gets conquered faster by Japan. Believe me I'd love to see china ai tunable so it looks aesthetically and historically wonderful and plays well too.

With that said, let me ask both of you: Do the changes you suggest actually make China survive longer? Have you tested it? Or do your own china ai files last the longest?

My last comment is that I have not tried this or any new ai files (mine or others) vs. human... I want to and I intend to but I haven't had time yet.
 

Steel

Field Marshal
56 Badges
May 4, 2001
7.689
0
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Mare Nostrum
  • Stellaris
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Hearts of Iron IV: Cadet
  • Europa Universalis IV: Rights of Man
  • Tyranny: Archon Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Hearts of Iron IV: Together for Victory
  • Pillars of Eternity
  • Steel Division: Normandy 44
  • Europa Universalis IV: Mandate of Heaven
  • Steel Division: Normandy 44 Deluxe Edition
  • Europa Universalis IV: Third Rome
  • BATTLETECH
  • Hearts of Iron IV: Death or Dishonor
  • Age of Wonders III
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Imperator: Rome - Magna Graecia
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Crusader Kings II
  • Hearts of Iron III
  • Majesty 2
  • Europa Universalis IV: Res Publica
  • Victoria 2
  • 500k Club
  • Cities: Skylines
  • Cities: Skylines Deluxe Edition
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Pre-order
  • Hearts of Iron II: Beta
I find it hard to believe that holding the navy back and not building pre-war aircraft would lead to a faster collapse ;) To answer your question, I've seen China survive until the end of the game as a neutral co-belligerent with the Allies and/or the Comintern as well as an alliance member of the Allies. However you will never write an AI file for China that achieves this on its own - it has to be done in conjunction with an AI Japan that is actually interested in conducting a campaign against Singapore, Burma, Dutch East Indies etc.
 

unmerged(14856)

First Lieutenant
Feb 18, 2003
234
0
Visit site
Hi Roxxor,
Since you didn't even point to specifics I created my own china.ai file, then tested both yours and my configuration in a handsoff game.

Both AIs collapsed after the invasion of Nanjing and the loss of all accumulated resources.

The difference was that mine repelled two invasions in Shanghai, mine also held the northern border far longer.

Yours was annexed in 410505, mine was collapsing and would have died in days but I got the lockup in 411213. (I don't use any mods to be sure it will work with vanilla 1.05)

Conclusions:
-We need to adjust the ai to lean even more towards defending Shanghai & Nanjing.
-Defending Jiangmen was useless if the assault on Shanghai was a success.
-Need to adjust the admiral more to save the fleet.
-In both games the AI stupidly had a naval bomber on the border to Siankiang, Don't know what to do about it...???
-My AI had problems with the building transport bug, yours didn't.

I have screendumps of both games with all key moments and I can post them if you want.

This was the ai that I used, yours I took from your post.
Code:
#
# file: china.ai
#
# Hearts of Iron
#
# By Spoon
#
# Nationalist China AI file
#

# 100 = Total warmonger, 0 = absolute pacifist
war = 40

combat = { CHC SIK }
strat_redeploy_threshold = 20
max_front_ratio = 6
max_garrison_prop = 0.5 
min_garrison_prop = 0.2
influence = { USA SIA JAP }


construction = {	#During periods of peace we will prepare for war.
	max_factor   = 0.2  #Max 20%
	max_AA    = 4	    
	AA_batteries   = not_atwar	
	max_AA_level  = 1    
	coastal_fort   = no
	ic_at_war   = no   
	force_ic_until  = 1938	#Build IC for two years this will improve most of our 1IC provinces   
	ic_end_year   = 1939	#By then it should be enough    
	max_land_level = 0
}

military = {
	relative_build_scheme 	= no
	
	infantry = 			75.6
	cavalry = 			10
	motorized = 		6	#We can convert our coal to oil
	mechanized =		0
	panzer = 			0	#Can't afford the research nor the production cost
	paratrooper = 		0
	marine = 			0
	bergsjaeger = 		1	#For fun and half our country is mountains
#						92.6 %
	fighter = 			4
	strategic_bomber = 	1	#For the suprise factor
	tactical_bomber = 	0.1	#Slim chance but for historical reasons it should be here
	naval_bomber = 		0.1	#Slim chance but for historical reasons it should be here
	dive_bomber = 		2	#The most effective bomber without spending the tech
	transport_plane = 	0 
	torpedo_plane = 		0
#						7.2 %
	battleship = 		0
	carrier = 			0
	destroyer = 		0.1	#Slim chance but for historical reasons it should be here
	cruiser = 			0.1	#Slim chance but for historical reasons it should be here
	submarine = 		0
	transports = 		0
#					0.2 %
}

technology = {

endgoal = {}
preference = {1202 1204 14008 14009}

electronics = 		0.001	#Minimum for historical reasons
armor = 			0
infantry = 			4.0	#Higher then artillery for the AI to prioritize this
industry = 			0.001	#Minimum for historical reasons
rocket = 			0
nuclear = 			0
heavy_aircraft = 		0.001	#Minimum for historical reasons
light_aircraft = 		0.001	#Minimum for historical reasons
naval = 			0.001	#Minimum for historical reasons
submarine = 		0.001	#Minimum for historical reasons
artillery = 		3.0
naval_doctrine = 		0.001	#Minimum for historical reasons
land_doctrine = 		0.1	#They should at least try to get one or two
air_doctrine = 		0.001	#Minimum for historical reasons
}

garrison = {

defend_overseas_beaches = no

# PRIORITIES:
beach_1 = 50 # Beach level 1
beach_2 = 55 # Beach level 2
beach_3 = 60 # Beach level 3
capital = 100 # Our capital
human_border = 0 # Ignored for allied human players
war_target = 20 # The next country targeted for attack by this AI

opposing_alliance = 0 # For neutrals, all alliances are "opposing"
claim_threat = 0 # If we are neutral, countries with claims on us get this
unstable_border = 30 # Bordering countries at war with someone else get this

# Borders with specific countries
country_priorities = {
ENG = -1
SOV = -1
TRK = -1
FRA = -1
TIB = -1
NEP = -1
SIK = -1
CHC = 50
JAP = 500
}
# Specific provinces
province_priorities = {

1562 = 70 #Jinzhou (JPN)

1567 = 41 #Datong
1698 = 201 #Shanghai
1620 = 82 #Xuzhou

1616 = 10	# Yanan (CHC)
1700 = 11	# Xianyang (CHC)

}

key_point_prio_mult = 1
}

front = { 
            recklessness = 0 
            enemy_reinf_days = 30 
            reserve_prop = 0.300 
            panic_ratio_vs_ai = 1.500 
            panic_ratio_vs_human = 2.000 
            base_attack_odds = 3.500 
            min_attack_odds = 3.000 
            max_attack_odds = 4.000 
            reinforce_odds = 1.500 
            withdraw_odds = 0.800 
            distrib_vs_ai = even 
            distrib_vs_human = even 
            enemy_handicap = { } 
            passivity = { } 
} 

admiral = {
	target = {
	1723 = 500 #Bobai Sea
	}
}
bomber = {
	
#defensive fighter ai factors
	
	defensiveIC		= 3.0
	recentlyBombed	= 7.0   #protect anything bombed.
	protectOil		= 1.2
	protectCoal		= 1.1
	protectSteel	= 1.0
	protectRubber	= 1.3
	
#Evaluation factors for determening which landarea to be strategically bombarded.	
	
	areaSize		= 2.0	#size of area.
	areaDistance	= 1.0	#distance
	adjacency		= 4.0	#if its neighbor to us.
	
#Evaluate which province to get a bombing mission.
	
	targetIC		= 3.0	#How important are IC to target..  
	avoidAA		= 8.0	#how bad AA are.
	targetCoal		= 2.0
	targetSteel		= 2.0
	targetOil		= 20.0	
	targetRubber	= 30.0
	occupied		= 0.1	#Subtract for provinces which are occupied, ie bomb germany ahead of france as UK.
	
}
 

unmerged(14856)

First Lieutenant
Feb 18, 2003
234
0
Visit site
This one did much better.

Even though Nanjing fell in June 38 it didn't collapse afterwards.

Instead it launched an effective counterattack in the north pushing the japs back a year.

The whole coast was conquered in Jan 40 but still it didn't collapse, when the Japs joined the axis and got attacked by the brits in Mar 41 it was alive and cicking.

The AA proved useful on numerous occasions, might want to experiment with that.

Problems
-The Nav bomber was still sitting tight in Xiang the whole time.
-The navy never got out of shanghai harbor.
-Only repulsed the first invasion of shanghai, on the second one the Japs crushed all resistance.

Code:
#
# file: china.ai
#
# Hearts of Iron
#
# By Spoon
#
# Nationalist China AI file
#

# 100 = Total warmonger, 0 = absolute pacifist
war = 60

combat = { CHC SIK }
strat_redeploy_threshold = 20
max_front_ratio = 8
max_garrison_prop = 0.6 
min_garrison_prop = 0.2
influence = { USA SIA JAP SOV }


construction = {	#During periods of peace we will prepare for war.
	max_factor   = 0.2  #Max 20%
	max_AA    = 4	    
	AA_batteries   = not_atwar	
	max_AA_level  = 1    
	coastal_fort   = no
	ic_at_war   = no   
	force_ic_until  = 1937	#Build IC for a year this will improve most of our 1IC provinces   
	ic_end_year   = 1939	#By then it should be enough    
	max_land_level = 0
}

military = {
	relative_build_scheme 	= no
	
	infantry = 			75.6
	cavalry = 			10
	motorized = 		6	#We can convert our coal to oil
	mechanized =		0
	panzer = 			0	#Can't afford the research nor the production cost
	paratrooper = 		0
	marine = 			0
	bergsjaeger = 		1	#For fun and half our country is mountains
#						92.6 %
	fighter = 			4
	strategic_bomber = 	1	#For the suprise factor
	tactical_bomber = 	0.1	#Slim chance but for historical reasons it should be here
	naval_bomber = 		0.1	#Slim chance but for historical reasons it should be here
	dive_bomber = 		2	#The most effective bomber without spending the tech
	transport_plane = 	0 
	torpedo_plane = 		0
#						7.2 %
	battleship = 		0
	carrier = 			0
	destroyer = 		0.1	#Slim chance but for historical reasons it should be here
	cruiser = 			0.1	#Slim chance but for historical reasons it should be here
	submarine = 		0
	transports = 		0.0
#					0.2%
}

technology = {

endgoal = {}
preference = {1202 1204 14008 14009}

electronics = 		0.001	#Minimum for historical reasons
armor = 			0
infantry = 			3.0	#Higher then artillery for the AI to prioritize this
industry = 			0.001	#Minimum for historical reasons
rocket = 			0
nuclear = 			0
heavy_aircraft = 		0.001	#Minimum for historical reasons
light_aircraft = 		0.001	#Minimum for historical reasons
naval = 			0.001	#Minimum for historical reasons
submarine = 		0.001	#Minimum for historical reasons
artillery = 		4.0
naval_doctrine = 		0.001	#Minimum for historical reasons
land_doctrine = 		0.1	#They should at least try to get one or two
air_doctrine = 		0.001	#Minimum for historical reasons
}

garrison = {

defend_overseas_beaches = no

# PRIORITIES:
beach_1 = 60 # Beach level 1
beach_2 = 65 # Beach level 2
beach_3 = 70 # Beach level 3
capital = 75 # Our capital
human_border = 0 # Ignored for allied human players
war_target = 20 # The next country targeted for attack by this AI

opposing_alliance = 0 # For neutrals, all alliances are "opposing"
claim_threat = 0 # If we are neutral, countries with claims on us get this
unstable_border = 30 # Bordering countries at war with someone else get this

# Borders with specific countries
country_priorities = {
ENG = -1
SOV = -1
TRK = -1
FRA = -1
TIB = -1
NEP = -1
SIK = -1
JAP = 500
}
# Specific provinces
province_priorities = {

1562 = 70 #Jinzhou (JPN)
1561 = 51 #Dalian (JPN)

1563 = 113 #Baijing
1567 = 91 #Datong
1698 = 151 #Shanghai
1620 = 102 #Xuzhou
1625 = 147 #Tianjin

#in an attempt to remove troops from here
1542 = -100 #Anxi 
1572 = -100 #Jinchuan

#in an attempt to take this territories if they fall to japan
1571 = 150	# Yanan (CHC)
1570 = 151	# Xianyang (CHC)

}

key_point_prio_mult = 1
}

front = { 
            recklessness = 0 
            enemy_reinf_days = 40 
            reserve_prop = 0.200 
            panic_ratio_vs_ai = 1.500 
            panic_ratio_vs_human = 2.000 
            base_attack_odds = 2.000 
            min_attack_odds = 1.000 
            max_attack_odds = 5.000 
            reinforce_odds = 2.000 
            withdraw_odds = 0.900 
            distrib_vs_ai = even 
            distrib_vs_human = even 
            enemy_handicap = { } 
            passivity = { } 
} 

admiral = {
	target = {
	1719 = 50 #Hong Kong sea
	1723 = 100 #Bobai Sea
	}
}
bomber = {
	
#defensive fighter ai factors
	
	defensiveIC		= 2.0
	recentlyBombed	= 10.0   #protect anything bombed.
	protectOil		= 1.2
	protectCoal		= 1.1
	protectSteel	= 1.0
	protectRubber	= 1.3
	
#Evaluation factors for determening which landarea to be strategically bombarded.	
	
	areaSize		= 2.0	#size of area.
	areaDistance	= 1.0	#distance
	adjacency		= 4.0	#if its neighbor to us.
	
#Evaluate which province to get a bombing mission.
	
	targetIC		= 13.0	#How important are IC to target..  
	avoidAA		= 8.0	#how bad AA are.
	targetCoal		= 12.0
	targetSteel		= 12.0
	targetOil		= 20.0	
	targetRubber	= 30.0
	occupied		= 0.0	#Subtract for provinces which are occupied, ie bomb germany ahead of france as UK.
	
}
 

unmerged(14856)

First Lieutenant
Feb 18, 2003
234
0
Visit site
Tweaked it a bit more and I created a monster...
:(
It would actually drive the japs back to the Korean peninsula.

So now I'm trying to give it a passivity to see if that helps any.

Still these problems remain and if I could get any help to solve them I'd be happy.

  • The China.ai will always place an airunit in Anxi, usually a NAV bomber.
    Now the Anxi province is on the NW border to Mongolia for heavens sake, it is as far away from the coast as they can get.
  • Still cant get the navy to move its lazy ass so its killed off with the invasion of shanghai.
    Ive tried high admiral values, low values, negative values for the harbors it get stuck in, any ideas?
 

unmerged(14102)

Field Marshal
Jan 27, 2003
5.515
0
Visit site
Originally posted by Steel
IMHO you are making a mistake with the construction. You are ensuring that China will never build up their numerous low-IC areas (high ROI) and never build AA (very high ROI). This will cut deeply into long-term viability of western China and the AI will be struggling to meet supply requirements.

But historically, this was quite true. They did NOT buld up their industry nor their technology much in this period. Rationale was as given B4: warlord inability to coordinate and concern of jsut giving it to the Japanese. The burma road was critical and the allies supported it strongly to keep Japan tied up in China while they could recover. To similate this, we simply need to add events to trigger supplies arriving periodically, maybe quarterly, and maybe a few IC bumps as well similar to the lend-lease code.

Regarding the airforce, similar arguements: The Flying Tigers followed by tech transfer from allies to build these on their own. They did not research this AFAIK. So again, a couple of events, one to transfer a few fighter squads of P-40's to china, followed a few months later by a tech transfer for the R&D.

Finally, losing Rangoon has to be a catastrophic event for china. major hit ... remove IC's gained by events, dissent penalty, they should surrender to Japan in 80% of the time within 18 months.

All of this is just IMHO. Thoughts welcome. I ahve some of these events already coded ....
 

Steel

Field Marshal
56 Badges
May 4, 2001
7.689
0
  • Stellaris - Path to Destruction bundle
  • Europa Universalis IV: Common Sense
  • Europa Universalis IV: Cossacks
  • Europa Universalis IV: Mare Nostrum
  • Stellaris
  • Stellaris: Galaxy Edition
  • Stellaris: Galaxy Edition
  • Hearts of Iron IV: Cadet
  • Europa Universalis IV: Rights of Man
  • Tyranny: Archon Edition
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Hearts of Iron IV: Together for Victory
  • Pillars of Eternity
  • Steel Division: Normandy 44
  • Europa Universalis IV: Mandate of Heaven
  • Steel Division: Normandy 44 Deluxe Edition
  • Europa Universalis IV: Third Rome
  • BATTLETECH
  • Hearts of Iron IV: Death or Dishonor
  • Age of Wonders III
  • Europa Universalis IV: Cradle of Civilization
  • Hearts of Iron IV: Expansion Pass
  • Shadowrun: Dragonfall
  • Shadowrun: Hong Kong
  • Imperator: Rome - Magna Graecia
  • Europa Universalis IV: Call to arms event
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • Crusader Kings II
  • Hearts of Iron III
  • Majesty 2
  • Europa Universalis IV: Res Publica
  • Victoria 2
  • 500k Club
  • Cities: Skylines
  • Cities: Skylines Deluxe Edition
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Pre-order
  • Hearts of Iron II: Beta
Originally posted by PaxMondo
But historically, this was quite true. They did NOT buld up their industry nor their technology much in this period. Rationale was as given B4: warlord inability to coordinate and concern of jsut giving it to the Japanese. The burma road was critical and the allies supported it strongly to keep Japan tied up in China while they could recover. To similate this, we simply need to add events to trigger supplies arriving periodically, maybe quarterly, and maybe a few IC bumps as well similar to the lend-lease code.

Regarding the airforce, similar arguements: The Flying Tigers followed by tech transfer from allies to build these on their own. They did not research this AFAIK. So again, a couple of events, one to transfer a few fighter squads of P-40's to china, followed a few months later by a tech transfer for the R&D.

Finally, losing Rangoon has to be a catastrophic event for china. major hit ... remove IC's gained by events, dissent penalty, they should surrender to Japan in 80% of the time within 18 months.

All of this is just IMHO. Thoughts welcome. I ahve some of these events already coded ....


Fair points, but with the ban on new events how will this get into HoI? Piggy-back on existing events without an update to the desc text is a bit dodgy IMHO. The points I'm making are from the AI Project perspective of using the existing structure to build the best AI.
 

Thufir Hawat

Mentat, Master of Assassins
41 Badges
Mar 29, 2003
172
0
38
  • Stellaris: Apocalypse
  • Hearts of Iron IV: Cadet
  • Crusader Kings II: Reapers Due
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Crusader Kings II: Monks and Mystics
  • Stellaris - Path to Destruction bundle
  • BATTLETECH
  • Stellaris: Synthetic Dawn
  • Crusader Kings II: Jade Dragon
  • Stellaris: Humanoids Species Pack
  • Stellaris
  • BATTLETECH - Digital Deluxe Edition
  • Stellaris: Distant Stars
  • Stellaris: Megacorp
  • Crusader Kings II: Holy Fury
  • Stellaris: Ancient Relics
  • Stellaris: Lithoids
  • Stellaris: Federations
  • Crusader Kings III
  • Stellaris: Necroids
  • Europa Universalis III: Chronicles
  • Crusader Kings II
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Cities in Motion
  • Victoria: Revolutions
  • Victoria 2
  • Victoria 2: A House Divided
  • Victoria 2: Heart of Darkness
  • 500k Club
  • Mount & Blade: With Fire and Sword
  • Crusader Kings II: Way of Life
  • Crusader Kings II: Horse Lords
  • Crusader Kings II: Conclave
Originally posted by Spoonist
The China.ai will always place an airunit in Anxi, usually a NAV bomber.
Now the Anxi province is on the NW border to Mongolia for heavens sake, it is as far away from the coast as they can get.


My 2 cents: considering that SIK is listed in the combat = section of your AI, and that there is a war_target garrison value of 20, there might be a reason for your China AI to post something there, even if it is specifically prohibited otherwise ( country_priorities having SIK = -1 ). Other than that, I have no clue. Probably something to do with the defensive fighter factors, or maybe that key_point_prio_mult is not 0, as was suggested in the discussion of AI variables thread.
 

unmerged(14856)

First Lieutenant
Feb 18, 2003
234
0
Visit site
-> Thufir Hawat
Good point, might have to remove that war garrison...
:eek:
Anxi is no keypoint, but it does contain some resources, will have to test.

Good points.

BTW
key_point_prio_mult = 1
Worked like a charm for china, I agree that most countries shouldnt have it but some works that much better if they do.