##### Division Templates #####
division_template = {
	name = "División de Infantería" 		# Used for both regular infantry divisions and larger garrison divisions
	division_names_group = SPR_INF_01
	# Note: Spanish divisions were 2x brigades of 2x2 rgts each, + support
	regiments = {
		infantry = { x = 0 y = 0 }
		infantry = { x = 0 y = 1 }
		infantry = { x = 0 y = 2 }
		infantry = { x = 0 y = 3 }
		infantry = { x = 1 y = 0 }
		infantry = { x = 1 y = 1 }
		infantry = { x = 1 y = 2 }
		infantry = { x = 1 y = 3 }
	}
	support = {
		artillery = { x = 0 y = 0 }  # Spanish Arty Rgt/Bge had 2 Bn 105mm arty
		engineer = { x = 0 y = 1 }   # Eng Bn
	}
}
division_template = {
	name = "División de Caballería"  		# Only one Cavalry Division (3x bge of 2x2 Rgts)
	division_names_group = SPR_CAV_01

	regiments = {
		cavalry = { x = 0 y = 0 }
		cavalry = { x = 0 y = 1 }
		cavalry = { x = 0 y = 2 }
		cavalry = { x = 0 y = 3 }
		cavalry = { x = 1 y = 0 }
		cavalry = { x = 1 y = 1 }
		cavalry = { x = 1 y = 2 }
		cavalry = { x = 1 y = 3 }
		cavalry = { x = 2 y = 0 }
		cavalry = { x = 2 y = 1 }
		cavalry = { x = 2 y = 2 }
		cavalry = { x = 2 y = 3 }
	}
	support = {
		recon = { x = 0 y = 0 }      # Recon consisted of motorcycles and ACs
	}
}
division_template = {
	name = "Brigada Montaña"  		# Mountain Brigades were 2x2 Rgts + support
	division_names_group = SPR_MNT_01
	regiments = {
		mountaineers = { x = 0 y = 0 }	
		mountaineers = { x = 0 y = 1 }
		mountaineers = { x = 1 y = 0 }
		mountaineers = { x = 1 y = 1 }
	}
	support = {
		artillery = { x = 0 y = 0 }  # Spanish Arty Rgt/Bge had 2 Bn 105mm arty
	}
}
division_template = {
	name = "Brigada de Infantería" 		# Infantry Brigade - Used for smaller garrison units
	division_names_group = SPR_GAR_01

	regiments = {
		infantry = { x = 0 y = 0 }	
		infantry = { x = 0 y = 1 }	
		infantry = { x = 1 y = 0 }	
		infantry = { x = 1 y = 1 }	
	}
	support = {
		engineer = { x = 0 y = 0 }   # Eng Bn
	}
}

###### OOB ######
units = {
	#####LAND UNITS #####
	### MAINLAND UNITS ###
	division = { # "1a División de Infantería"		
		division_name = {
				is_name_ordered = yes
				name_order = 1
		}
		location = 3938  # Madrid
		division_template = "División de Infantería"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			
	division = { # "2a División de Infantería"		
		division_name = {
				is_name_ordered = yes
				name_order = 2
		}
		location = 7183  # Sevilla
		division_template = "División de Infantería"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			
	division = { # "3a División de Infantería"		
		division_name = {
				is_name_ordered = yes
				name_order = 3
		}
		location = 6906  # Valencia
		division_template = "División de Infantería"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			
	division = { # "4a División de Infantería"		
		division_name = {
				is_name_ordered = yes
				name_order = 4
		}
		location = 9764  # Barcelona
		division_template = "División de Infantería"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			
	division = { # "5a División de Infantería"		
		division_name = {
				is_name_ordered = yes
				name_order = 5
		}
		location = 3816  # Zaragosa
		division_template = "División de Infantería"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			
	division = { # "6a División de Infantería"		
		division_name = {
				is_name_ordered = yes
				name_order = 6
		}
		location = 885  # Burgos
		division_template = "División de Infantería"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			
	division = { # "7a División de Infantería"		
		division_name = {
				is_name_ordered = yes
				name_order = 7
		}
		location = 11825  # Valladolid
		division_template = "División de Infantería"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			
	division = { # "8a División de Infantería"		
		division_name = {
				is_name_ordered = yes
				name_order = 8
		}
		location = 758  # La Coruña
		division_template = "División de Infantería"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			

	division = { # "1a División de Caballería"		
		division_name = {
				is_name_ordered = yes
				name_order = 1
		}
		location = 9764  # Barcelona
		division_template = "División de Caballería"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			

	division = {			
		name = "1a Brigada Montaña"		
		location = 13071  # Canary Islands
		division_template = "Brigada Montaña"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			
	division = {			
		name = "2a Brigada Montaña"		
		location = 740  #Bilbao
		division_template = "Brigada Montaña"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			
	division = {			
		name = "Brigada Mixta Montaña"		
		location = 11707  #Oviedo
		division_template = "Brigada Montaña"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			

	division = {			
		name = "Brigada de Arma de Infantería"		
		location = 1048  #Cádiz
		division_template = "Brigada de Infantería"
		start_experience_factor = 0.2
		start_equipment_factor = 0.8

	}			


	### Island Garrisons ###
	division = { # "Comandancia de Baleares"		
		division_name = {
				is_name_ordered = yes
				name_order = 1
		}
		location = 9793  #Mallorca
		division_template = "Brigada de Infantería"		# garrison division, lower equipment, experience
		force_equipment_variants = { infantry_equipment_0 = { owner = "SPR" } }
		start_experience_factor = 0.1
		start_equipment_factor = 0.5

	}			
	division = { # "Comandancia de Canarias"		
		division_name = {
				is_name_ordered = yes
				name_order = 2
		}
		location = 13071  # Canary Islands
		division_template = "Brigada de Infantería"		# garrison division, lower equipment, experience
		force_equipment_variants = { infantry_equipment_0 = { owner = "SPR" } }
		start_experience_factor = 0.1
		start_equipment_factor = 0.5

	}			


	### Ejército de África ###
	division = {			
		name = "Circunscripción Occidental"		
		location = 9945  #Ceuta
		division_template = "División de Infantería"		# garrison division, lower equipment, experience
		start_experience_factor = 0.1
		start_equipment_factor = 0.8

	}			
	division = {			
		name = "Circunscripción Oriental"		
		location = 12100  #Melilla
		division_template = "División de Infantería"		# garrison division, lower equipment, experience
		start_experience_factor = 0.1
		start_equipment_factor = 0.8

	}			
}


instant_effect = {
	add_equipment_production = {
		equipment = {
			type = infantry_equipment_1
			creator = "SPR"
		}
		requested_factories = 2
		progress = 0.42
		efficiency = 100
	}
	add_equipment_production = {
		equipment = {
			type = support_equipment_1
			creator = "SPR"
		}
		requested_factories = 1
		progress = 0.24
		efficiency = 100
	}
	add_equipment_production = {
		equipment = {
			type = artillery_equipment_1
			creator = "SPR"
		}
		requested_factories = 1
		progress = 0.24
		efficiency = 100
	}
}