﻿MILITARY_FORMATIONS = {
	c:BRZ ?= {
		create_military_formation = {
			type = army
			hq_region = sr:region_brazil
			name = Exrcito_do_Sul

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_MINAS_GERAIS
				count = 2
			}

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_RIO_DE_JANEIRO
				count = 1
			}

			combat_unit = {
				type = unit_type:combat_unit_type_irregular_infantry
				state_region = s:STATE_SAO_PAULO
				count = 4
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_PERNAMBUCO
				count = 1
			}
		}

		create_military_formation = {
			type = army
			hq_region = sr:region_brazil
			name = Exrcito_do_Amazonas

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_BAHIA
				count = 2
			}

			combat_unit = {
				type = unit_type:combat_unit_type_irregular_infantry
				state_region = s:STATE_SANTA_CATARINA
				count = 3
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_PERNAMBUCO
				count = 1
			}
		}

		create_military_formation = {
			type = army
			hq_region = sr:region_brazil
			name = Exrcito_Imperial_Brasileiro

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_RIO_DE_JANEIRO
				count = 1
			}

			combat_unit = {
				type = unit_type:combat_unit_type_irregular_infantry
				state_region = s:STATE_RIO_DE_JANEIRO
				count = 2
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_PARAIBA
				count = 1
			}
		}

		create_military_formation = {
			type = fleet
			hq_region = sr:region_brazil
			name = Armada_Nacional
		
			combat_unit = {
				type = unit_type:combat_unit_type_man_o_war
				state_region = s:STATE_RIO_DE_JANEIRO
				count = 1
			}

			combat_unit = {
				type = unit_type:combat_unit_type_frigate
				state_region = s:STATE_BAHIA
				count = 3
			}

			combat_unit = {
				type = unit_type:combat_unit_type_frigate
				state_region = s:STATE_RIO_DE_JANEIRO
				count = 6
			}
		}
	}

	c:CHL ?= {
		create_military_formation = {
			type = army
			hq_region = sr:region_la_plata
			name = Ejrcito_de_Chile

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_SANTIAGO
				count = 5
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_SANTIAGO
				count = 5
			}
		}

		create_military_formation = {
			type = fleet
			hq_region = sr:region_la_plata
			name = Armada_de_Chile

			combat_unit = {
				type = unit_type:combat_unit_type_frigate
				state_region = s:STATE_SANTIAGO
				count = 1
			}
		}
	}

	c:ARG ?= {
		create_military_formation = {
			type = army
			hq_region = sr:region_la_plata
			name = Ejrcito_Argentino # No organized army really existed in 1836, but an ad-hoc 'Northern Army' was formed in 1837

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_BUENOS_AIRES
				count = 5
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_BUENOS_AIRES
				count = 5
			}
		}

		create_military_formation = {
			type = fleet
			hq_region = sr:region_la_plata
			name = Armada_Argentina

			combat_unit = { # Nothing the size of a frigate
				type = unit_type:combat_unit_type_frigate
				state_region = s:STATE_BUENOS_AIRES
				count = 1
			}
		}
	}

	c:PRA ?= {
		create_military_formation = {
			type = army
			hq_region = sr:region_brazil
			name = Exrcito_Cabano

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_PARA
				count = 1
			}

			combat_unit = {
				type = unit_type:combat_unit_type_irregular_infantry
				state_region = s:STATE_PARA
				count = 7
			}

			combat_unit = {
				type = unit_type:combat_unit_type_irregular_infantry
				state_region = s:STATE_AMAZONAS
				count = 4
			}
			save_scope_as = firstarmypra
		}

		create_character = {
			template = PRA_Manuel_Lopes
			first_name = Manuel
			commander_rank = commander_rank_1
			save_scope_as = pra_general_gen
		}

		scope:pra_general_gen = {
			transfer_to_formation = scope:firstarmypra
		}
	}

	c:PNI ?= {
		create_military_formation = {
			type = army
			hq_region = sr:region_brazil
			name = Exrcito_Republicano_do_Rio_Grande

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_RIO_GRANDE_DO_SUL
				count = 3
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_RIO_GRANDE_DO_SUL
				count = 1
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_RIO_GRANDE_DO_SUL
				count = 1
			}

			combat_unit = {
				type = unit_type:combat_unit_type_irregular_infantry
				state_region = s:STATE_RIO_GRANDE_DO_SUL
				count = 4
			}
		}
	}

	c:ECU ?= {
		create_military_formation = {
			type = army
			hq_region = sr:region_andes
			name = Ejrcito_del_Ecuador

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_ECUADOR
				count = 5
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_ECUADOR
				count = 5
			}
		}
	}

	c:CLM ?= {
		create_military_formation = {
			type = army
			hq_region = sr:region_gran_colombia
			name = Ejrcito_de_la_Nueva_Granada

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_CUNDINAMARCA
				count = 5
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_ANTIOQUIA
				count = 5
			}
		}
	}

	c:VNZ ?= {
		create_military_formation = {
			type = army
			hq_region = sr:region_gran_colombia
			name = Ejrcito_de_Venezuela

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_ZULIA
				count = 5
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_ZULIA
				count = 5
			}
		}
	}

	c:URU ?= {
		create_military_formation = {
			type = army
			hq_region = sr:region_brazil
			name = Ejrcito_Nacional

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_URUGUAY
				count = 3
			}

			combat_unit = {
				type = unit_type:combat_unit_type_lancers
				state_region = s:STATE_URUGUAY
				count = 1
			}
		}
	}

	c:PRG ?= {
		create_military_formation = {
			type = army
			hq_region = sr:region_la_plata
			name = Ejrcito_Paraguayo

			combat_unit = {
				type = unit_type:combat_unit_type_line_infantry
				state_region = s:STATE_BAJO_PARAGUAY
				count = 5
			}
		}
	}
}
