# For minor countries where advisors are not defined
# Generate them from a generic template
# Something about this isn't working, many minors don't seem to have their generated advisors.

# Military advisors
every_possible_country = {
	limit = {
		OR = { original_tag = MOR original_tag = KOR original_tag = SER  original_tag = SYR original_tag = LEB original_tag = EGY original_tag = JOR original_tag = CRO original_tag = LBA original_tag = INS original_tag = MAL original_tag = AZR original_tag = UKR original_tag = GEO original_tag = ARM original_tag = VIN original_tag = CAM original_tag = MNT original_tag = LIB original_tag = LAO original_tag = PAL original_tag = ALT original_tag = KAL original_tag = KAR original_tag = CRI original_tag = TAT original_tag = CIN original_tag = DAG original_tag = BYA original_tag = CKK original_tag = FER original_tag = YAK original_tag = VLA original_tag = KKP original_tag = YAM original_tag = TAY original_tag = OVO original_tag = NEN original_tag = KOM original_tag = ABK original_tag = KBK original_tag = NOA original_tag = VGE original_tag = BSK original_tag = KHI original_tag = BUK original_tag = UDM original_tag = CHU original_tag = MEL original_tag = HAR original_tag = TIG original_tag = AFA original_tag = BEG original_tag = GBA original_tag = SID original_tag = ORO original_tag = QEM original_tag = RIF original_tag = AOI original_tag = SMI original_tag = RAP original_tag = QUE original_tag = RIG original_tag = YUC original_tag = GAR original_tag = INC original_tag = MIS original_tag = MAY original_tag = INU original_tag = CHR original_tag = ITZ original_tag = NAH original_tag = IAS original_tag = GYA original_tag = CAY original_tag = SUR original_tag = BAH original_tag = WLA original_tag = KAT original_tag = BIA original_tag = CBV original_tag = BAR original_tag = EVE original_tag = SLV original_tag = BOS original_tag = KOS original_tag = MAC original_tag = SIL original_tag = KSH original_tag = LBV original_tag = SPM original_tag = TOS original_tag = PAP original_tag = TTS original_tag = GRN original_tag = ISR original_tag = KHA original_tag = SOK original_tag = BAS original_tag = CAT original_tag = GLC original_tag = NAV original_tag = COR original_tag = IVO original_tag = RCG original_tag = MAD original_tag = GDL original_tag = SHL original_tag = MEK original_tag = HAN original_tag = SAX original_tag = PRE original_tag = BAY original_tag = WUR original_tag = THU original_tag = HES original_tag = RHI original_tag = DNZ original_tag = WGR original_tag = DDR original_tag = UBD original_tag = RKB original_tag = RKN original_tag = RKG original_tag = RKU original_tag = RKO original_tag = RKK original_tag = RKM original_tag = RKL original_tag = GEN original_tag = RKH original_tag = RKI original_tag = RKC original_tag = RGB original_tag = RKA original_tag = RNA original_tag = RKV original_tag = RAN original_tag = RCO original_tag = RUS original_tag = RHD original_tag = RAR original_tag = ROA original_tag = RAA original_tag = DON original_tag = KUB original_tag = BLR original_tag = DIP original_tag = PSH original_tag = HYD original_tag = MYS original_tag = RJP original_tag = CIP original_tag = RAS original_tag = NWF original_tag = KAS original_tag = MPU original_tag = WIS original_tag = KOL original_tag = KHL original_tag = SIN original_tag = KLT original_tag = SKK original_tag = FSA original_tag = ASY original_tag = BHR original_tag = IMO original_tag = BLC 
		}
	}
	# generic political advisors
	generate_character = {
		token_base = generic_captain_of_industry # token will be TAG_token_base
		advisor = {
			slot = political_advisor
			traits = { captain_of_industry }
		}
		portraits = { 
			army = { small = GFX_idea_generic_captain_of_industry }
		}
	}
	generate_character = {
		token_base = generic_fortification_engineer # token will be TAG_token_base
		advisor = {
			slot = political_advisor
			traits = { fortification_engineer }
		}
		portraits = { 
			army = { small = GFX_idea_generic_fortification_engineer }
		}
	}
	generate_character = {
		token_base = generic_war_industrialist # token will be TAG_token_base
		advisor = {
			slot = political_advisor
			traits = { war_industrialist }
		}
		portraits = { 
			army = { small = GFX_idea_generic_war_industrialist }
		}
	}
	# generic army chiefs
	generate_character = {
		token_base = generic_army_chief_off # token will be TAG_token_base
		advisor = {
			slot = army_chief
			traits = { army_chief_offensive_1 }
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_army_chief_off }
		}
	}
	generate_character = {
		token_base = generic_army_chief_def # token will be TAG_token_base
		advisor = {
			slot = army_chief
			traits = { army_chief_defensive_1 }
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_army_chief_def }
		}
	}
	# generic navy chiefs
	generate_character = {
		token_base = generic_navy_chief_decisive_bat # token will be TAG_token_base
		advisor = {
			slot = navy_chief
			traits = { navy_chief_decisive_battle_2 }
			cost = 100
		}
		portraits = { 
			army = { small = GFX_idea_generic_navy_chief_decisive_bat }
		}
	}
	generate_character = {
		token_base = generic_navy_anti_submarine # token will be TAG_token_base
		advisor = {
			slot = navy_chief
			traits = { navy_anti_submarine_2 }
			cost = 100
		}
		portraits = { 
			army = { small = GFX_idea_generic_navy_anti_submarine }
		}
	}
	# generic air chiefs
	generate_character = {
		token_base = generic_air_close_air_sup # token will be TAG_token_base
		advisor = {
			slot = air_chief
			traits = { air_chief_ground_support_2 }
			cost = 100
		}
		portraits = { 
			army = { small = GFX_idea_generic_air_close_air_sup }
		}
	}
	generate_character = {
		token_base = generic_air_chief_all_weather # token will be TAG_token_base
		advisor = {
			slot = air_chief
			traits = { air_chief_all_weather_2 }
			cost = 100
		}
		portraits = { 
			army = { small = GFX_idea_generic_air_chief_all_weather }
		}
	}
	# generic high command
	generate_character = {
		token_base = generic_army_art # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { army_artillery_1 }
			ledger = army
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_army_art }
		}
	}
	generate_character = {
		token_base = generic_army_log # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { army_logistics_2 }
			ledger = army
			cost = 100
		}
		portraits = { 
			army = { small = GFX_idea_generic_army_log }
		}
	}
	generate_character = {
		token_base = generic_navy_fleet_log # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { navy_fleet_logistics_1 }
			ledger = navy
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_navy_fleet_log }
		}
	}
	generate_character = {
		token_base = generic_air_air_combat_trainer # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { air_air_combat_training_2 }
			ledger = air
			cost = 100
		}
		portraits = { 
			army = { small = GFX_idea_generic_air_air_combat_trainer }
		}
	}
	# generic theorists
	generate_character = {
		token_base = generic_military_theorist # token will be TAG_token_base
		advisor = {
			slot = theorist
			traits = { military_theorist }
			ledger = army
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_military_theorist }
		}
	}
	generate_character = {
		token_base = generic_naval_theorist # token will be TAG_token_base
		advisor = {
			slot = theorist
			traits = { naval_theorist }
			ledger = navy
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_naval_theorist }
		}
	}
	generate_character = {
		token_base = generic_air_warfare_theorist # token will be TAG_token_base
		advisor = {
			slot = theorist
			traits = { air_warfare_theorist }
			ledger = air
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_air_warfare_theorist }
		}
	}
}

every_possible_country = {
	limit = {
		original_tag = MAN
	}
	generate_character = {
		token_base = generic_captain_of_industry # token will be TAG_token_base
		advisor = {
			slot = political_advisor
			traits = { captain_of_industry }
		}
		portraits = { 
			army = { small = GFX_idea_generic_captain_of_industry }
		}
	}
	generate_character = {
		token_base = generic_fortification_engineer # token will be TAG_token_base
		advisor = {
			slot = political_advisor
			traits = { fortification_engineer }
		}
		portraits = { 
			army = { small = GFX_idea_generic_fortification_engineer }
		}
	}
	generate_character = {
		token_base = generic_war_industrialist # token will be TAG_token_base
		advisor = {
			slot = political_advisor
			traits = { war_industrialist }
		}
		portraits = { 
			army = { small = GFX_idea_generic_war_industrialist }
		}
	}
	generate_character = { #Apparently MAN needs this to get an Illusive Gentleman with the new character sytem
		token_base = generic_head_of_intelligence # token will be TAG_token_base
		advisor = {
			slot = political_advisor
			traits = { head_of_intelligence }
			available = {
				has_intelligence_agency = yes
			}
			ai_will_do = {
				factor = 1
				modifier = {
					has_intelligence_agency = no
					factor = 0
				}
			}
		}
		portraits = { 
			army = { small = GFX_idea_generic_head_of_intelligence }
		}
	}
}

every_possible_country = { #Iceland is a special case
	limit = { 
		original_tag = ICE 
		has_dlc = "Arms Against Tyranny"
	}
	generate_character = {
		token_base = generic_army_art # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { army_artillery_1 }
			ledger = army
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_army_art }
		}
	}
	generate_character = {
		token_base = generic_army_log # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { army_logistics_2 }
			ledger = army
			cost = 100
		}
		portraits = { 
			army = { small = GFX_idea_generic_army_log }
		}
	}
	generate_character = {
		token_base = generic_navy_fleet_log # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { navy_fleet_logistics_1 }
			ledger = navy
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_navy_fleet_log }
		}
	}
	generate_character = {
		token_base = generic_air_air_combat_trainer # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { air_air_combat_training_2 }
			ledger = air
			cost = 100
		}
		portraits = { 
			army = { small = GFX_idea_generic_air_air_combat_trainer }
		}
	}
	# generic theorists
	generate_character = {
		token_base = generic_military_theorist # token will be TAG_token_base
		advisor = {
			slot = theorist
			traits = { military_theorist }
			ledger = army
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_military_theorist }
		}
	}
	generate_character = {
		token_base = generic_naval_theorist # token will be TAG_token_base
		advisor = {
			slot = theorist
			traits = { naval_theorist }
			ledger = navy
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_naval_theorist }
		}
	}
	generate_character = {
		token_base = generic_air_warfare_theorist # token will be TAG_token_base
		advisor = {
			slot = theorist
			traits = { air_warfare_theorist }
			ledger = air
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_air_warfare_theorist }
		}
	}
}

every_possible_country = { #BEL has no chief of navy, nor any naval theorists
	limit = {
		original_tag = BEL
	}
	generate_character = {
		token_base = generic_naval_theorist # token will be TAG_token_base
		advisor = {
			slot = theorist
			traits = { naval_theorist }
			ledger = navy
			cost = 100
		}
		portraits = { 
			army = { small = GFX_idea_generic_naval_theorist }
		}
	}
	generate_character = {
		token_base = navy_chief_reform # token will be TAG_token_base
		advisor = {
			slot = navy_chief
			traits = { navy_chief_reform_1 }
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_ENG_generic_navy_1 }
		}
	}
}

every_possible_country = { #IRQ has no chief of navy
	limit = {
		original_tag = IRQ
	}
	generate_character = {
		token_base = navy_chief_reform # token will be TAG_token_base
		advisor = {
			slot = navy_chief
			traits = { navy_chief_reform_1 }
			cost = 50
		}
		portraits = { 
			army = { small = GFX_idea_generic_navy_arab_3 }
		}
	}
}

every_possible_country = { #AFG has no chief of navy, nor any naval theorists
	limit = {
		original_tag = AFG
		has_dlc = "Graveyard of Empires"
	}
	generate_character = {
		token_base = generic_naval_theorist # token will be TAG_token_base
		advisor = {
			slot = theorist
			traits = { naval_theorist }
			ledger = navy
			cost = 50
			available = {
				has_completed_focus = AFG_naval_academy
			}
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_navy_1_small }
		}
	}
	generate_character = {
		token_base = navy_chief_reform # token will be TAG_token_base
		advisor = {
			slot = navy_chief
			traits = { navy_chief_reform_1 }
			cost = 50
			available = {
				has_completed_focus = AFG_naval_academy
			}
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_navy_2_small }
		}
	}
	generate_character = {
		token_base = generic_army_chief_off # token will be TAG_token_base
		advisor = {
			slot = army_chief
			traits = { army_chief_offensive_1 }
			cost = 50
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_land_1_small }
		}
	}
	generate_character = {
		token_base = generic_army_chief_def # token will be TAG_token_base
		advisor = {
			slot = army_chief
			traits = { army_chief_defensive_1 }
			cost = 50
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_land_2_small }
		}
	}
	generate_character = {
		token_base = generic_air_close_air_sup # token will be TAG_token_base
		advisor = {
			slot = air_chief
			traits = { air_close_air_support_2 }
			cost = 100
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_land_2_small }
		}
	}
	generate_character = {
		token_base = generic_air_chief_all_weather # token will be TAG_token_base
		advisor = {
			slot = air_chief
			traits = { air_chief_all_weather_2 }
			cost = 100
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_land_4_small }
		}
	}
		# generic high command
	generate_character = {
		token_base = generic_army_art # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { army_artillery_1 }
			ledger = army
			cost = 50
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_land_1_small }
		}
	}
	generate_character = {
		token_base = generic_army_log # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { army_logistics_2 }
			ledger = army
			cost = 100
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_land_2_small }
		}
	}
	generate_character = {
		token_base = generic_navy_fleet_log # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { navy_fleet_logistics_1 }
			ledger = navy
			cost = 50
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_navy_1_small }
		}
	}
	generate_character = {
		token_base = generic_air_air_combat_trainer # token will be TAG_token_base
		advisor = {
			slot = high_command
			traits = { air_air_combat_training_2 }
			ledger = air
			cost = 100
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_land_2_small }
		}
	}
	# generic theorists
	#generate_character = {
	#	token_base = generic_military_theorist # token will be TAG_token_base
	#	advisor = {
	#		slot = theorist
	#		traits = { military_theorist }
	#		ledger = army
	#		cost = 50
	#	}
	#	portraits = { 
	#		army = { small = GFX_portrait_AFG_generic_land_3_small }
	#	}
	#}
	generate_character = {
		token_base = generic_air_warfare_theorist # token will be TAG_token_base
		advisor = {
			slot = theorist
			traits = { air_warfare_theorist }
			ledger = air
			cost = 50
		}
		portraits = { 
			army = { small = GFX_portrait_AFG_generic_land_2_small }
		}
	}
}
