<?xml version="1.0" encoding="utf-8"?>
<Patch>

	<!-- ========== Adjust combatPower ========== -->

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/PawnKindDef[defName="Mech_Apocriton"]/combatPower</xpath>
		<value>
			<combatPower>900</combatPower>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/PawnKindDef[defName="Mech_Centurion"]/combatPower</xpath>
		<value>
			<combatPower>400</combatPower>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/PawnKindDef[defName="Mech_Warqueen"]/combatPower</xpath>
		<value>
			<combatPower>900</combatPower>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/PawnKindDef[defName="Mech_Diabolus"]/combatPower</xpath>
		<value>
			<combatPower>800</combatPower>
		</value>
	</Operation>

	<!-- ========== Loadouts ========== -->

	<Operation Class="PatchOperationAddModExtension">
		<xpath>Defs/PawnKindDef[defName="Mech_Apocriton"]</xpath>
		<value>
			<li Class="CombatExtended.LoadoutPropertiesExtension">
				<primaryMagazineCount>
					<min>9</min>
					<max>10</max>
				</primaryMagazineCount>
			</li>
		</value>
	</Operation>

	<!-- ========== Super Heavy Mechanoid ========== -->

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[@Name="SuperHeavyMechanoid"]/statBases/ArmorRating_Blunt</xpath>
		<value>
			<ArmorRating_Blunt>54</ArmorRating_Blunt>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[@Name="SuperHeavyMechanoid"]/statBases/ArmorRating_Sharp</xpath>
		<value>
			<ArmorRating_Sharp>24</ArmorRating_Sharp>
		</value>
	</Operation>

	<!-- ========== Apocriton ========== -->

	<Operation Class="PatchOperationAddModExtension">
		<xpath>Defs/ThingDef[defName="Mech_Apocriton"]</xpath>
		<value>
			<li Class="CombatExtended.RacePropertiesExtensionCE">
				<bodyShape>Humanoid</bodyShape>
			</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Mech_Apocriton"]/statBases</xpath>
		<value>
			<ArmorRating_Heat>0.5</ArmorRating_Heat>
			<CarryWeight>75</CarryWeight>
			<CarryBulk>40</CarryBulk>
			<MeleeDodgeChance>0.07</MeleeDodgeChance>
			<MeleeCritChance>0.13</MeleeCritChance>
			<MeleeParryChance>0.13</MeleeParryChance>
			<MaxHitPoints>600</MaxHitPoints>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Apocriton"]/statBases/ArmorRating_Blunt</xpath>
		<value>
			<ArmorRating_Blunt>60</ArmorRating_Blunt>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Apocriton"]/statBases/ArmorRating_Sharp</xpath>
		<value>
			<ArmorRating_Sharp>24</ArmorRating_Sharp>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Apocriton"]/statBases/EnergyShieldRechargeRate</xpath>
		<value>
			<EnergyShieldRechargeRate>0.375</EnergyShieldRechargeRate>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Apocriton"]/statBases/EnergyShieldEnergyMax</xpath>
		<value>
			<EnergyShieldEnergyMax>2.25</EnergyShieldEnergyMax>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Apocriton"]/tools</xpath>
		<value>
			<tools>
				<li Class="CombatExtended.ToolCE">
					<label>head</label>
					<capacities>
						<li>Blunt</li>
					</capacities>
					<power>10</power>
					<cooldownTime>2.0</cooldownTime>
					<linkedBodyPartsGroup>HeadAttackTool</linkedBodyPartsGroup>
					<ensureLinkedBodyPartsGroupAlwaysUsable>true</ensureLinkedBodyPartsGroupAlwaysUsable>
					<armorPenetrationBlunt>2.5</armorPenetrationBlunt>
				</li>
			</tools>
		</value>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/ThingDef[defName="Mech_Apocriton"]/comps</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/ThingDef[defName="Mech_Apocriton"]</xpath>
			<value>
				<comps />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Mech_Apocriton"]/comps</xpath>
		<value>
			<li Class="CombatExtended.CompProperties_ArmorDurability">
				<Durability>3100</Durability>
				<Regenerates>true</Regenerates>
				<RegenInterval>1250</RegenInterval>
				<RegenValue>5</RegenValue>
				<Repairable>true</Repairable>
				<RepairIngredients>
					<Steel>5</Steel>
					<Plasteel>5</Plasteel>
				</RepairIngredients>
				<RepairTime>300</RepairTime>
				<RepairValue>200</RepairValue>
				<MinArmorPct>0.5</MinArmorPct>
			</li>
		</value>
	</Operation>

	<!-- ========== Centurion ========== -->

	<Operation Class="PatchOperationAddModExtension">
		<xpath>Defs/ThingDef[defName="Mech_Centurion"]</xpath>
		<value>
			<li Class="CombatExtended.RacePropertiesExtensionCE">
				<bodyShape>Humanoid</bodyShape>
			</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Centurion"]/statBases/EnergyShieldRechargeRate</xpath>
		<value>
			<EnergyShieldRechargeRate>1.0</EnergyShieldRechargeRate>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Centurion"]/statBases/EnergyShieldEnergyMax</xpath>
		<value>
			<EnergyShieldEnergyMax>6.0</EnergyShieldEnergyMax>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Mech_Centurion"]/statBases</xpath>
		<value>
			<ArmorRating_Heat>0.25</ArmorRating_Heat>
			<CarryWeight>50</CarryWeight>
			<CarryBulk>50</CarryBulk>
			<AimingAccuracy>1.0</AimingAccuracy>
			<ShootingAccuracyPawn>1.0</ShootingAccuracyPawn>
			<MeleeDodgeChance>0.02</MeleeDodgeChance>
			<MeleeCritChance>0.20</MeleeCritChance>
			<MeleeParryChance>0.57</MeleeParryChance>
			<MaxHitPoints>550</MaxHitPoints>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Centurion"]/comps/li[@Class="CompProperties_ProjectileInterceptor"]/hitPoints</xpath>
		<value>
			<hitPoints>600</hitPoints>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Centurion"]/tools</xpath>
		<value>
			<tools>
				<li Class="CombatExtended.ToolCE">
					<label>head</label>
					<capacities>
						<li>Demolish</li>
					</capacities>
					<power>27</power>
					<cooldownTime>3.0</cooldownTime>
					<linkedBodyPartsGroup>HeadAttackTool</linkedBodyPartsGroup>
					<armorPenetrationBlunt>10</armorPenetrationBlunt>
					<chanceFactor>0.2</chanceFactor>
				</li>
			</tools>
		</value>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/ThingDef[defName="Mech_Centurion"]/comps</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/ThingDef[defName="Mech_Centurion"]</xpath>
			<value>
				<comps />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Mech_Centurion"]/comps</xpath>
		<value>
			<li Class="CombatExtended.CompProperties_ArmorDurability">
				<Durability>3300</Durability>
				<Regenerates>true</Regenerates>
				<RegenInterval>1250</RegenInterval>
				<RegenValue>5</RegenValue>
				<Repairable>true</Repairable>
				<RepairIngredients>
					<Steel>5</Steel>
					<Plasteel>5</Plasteel>
				</RepairIngredients>
				<RepairTime>300</RepairTime>
				<RepairValue>200</RepairValue>
				<MinArmorPct>0.5</MinArmorPct>
			</li>
		</value>
	</Operation>

	<!-- ========== Warqueen ========== -->

	<Operation Class="PatchOperationAddModExtension">
		<xpath>Defs/ThingDef[defName="Mech_Warqueen"]</xpath>
		<value>
			<li Class="CombatExtended.RacePropertiesExtensionCE">
				<bodyShape>QuadrupedLow</bodyShape>
			</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Warqueen"]/statBases/EnergyShieldRechargeRate</xpath>
		<value>
			<EnergyShieldRechargeRate>0.75</EnergyShieldRechargeRate>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Warqueen"]/statBases/EnergyShieldEnergyMax</xpath>
		<value>
			<EnergyShieldEnergyMax>4.5</EnergyShieldEnergyMax>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Mech_Warqueen"]/statBases</xpath>
		<value>
			<ArmorRating_Heat>0.5</ArmorRating_Heat>
			<CarryWeight>75</CarryWeight>
			<CarryBulk>50</CarryBulk>
			<AimingAccuracy>1.3</AimingAccuracy>
			<ShootingAccuracyPawn>1.25</ShootingAccuracyPawn>
			<MeleeDodgeChance>0.02</MeleeDodgeChance>
			<MeleeCritChance>0.22</MeleeCritChance>
			<MeleeParryChance>0.64</MeleeParryChance>
			<MaxHitPoints>600</MaxHitPoints>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Warqueen"]/tools</xpath>
		<value>
			<tools>
				<li Class="CombatExtended.ToolCE">
					<label>head</label>
					<capacities>
						<li>Blunt</li>
					</capacities>
					<power>10</power>
					<cooldownTime>2.0</cooldownTime>
					<linkedBodyPartsGroup>HeadAttackTool</linkedBodyPartsGroup>
					<ensureLinkedBodyPartsGroupAlwaysUsable>true</ensureLinkedBodyPartsGroupAlwaysUsable>
					<armorPenetrationBlunt>2.0</armorPenetrationBlunt>
					<chanceFactor>0.2</chanceFactor>
				</li>
			</tools>
		</value>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/ThingDef[defName="Mech_Warqueen"]/comps</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/ThingDef[defName="Mech_Warqueen"]</xpath>
			<value>
				<comps />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Mech_Warqueen"]/comps</xpath>
		<value>
			<li Class="CombatExtended.CompProperties_ArmorDurability">
				<Durability>4600</Durability>
				<Regenerates>true</Regenerates>
				<RegenInterval>1250</RegenInterval>
				<RegenValue>5</RegenValue>
				<Repairable>true</Repairable>
				<RepairIngredients>
					<Steel>5</Steel>
					<Plasteel>5</Plasteel>
				</RepairIngredients>
				<RepairTime>300</RepairTime>
				<RepairValue>200</RepairValue>
				<MinArmorPct>0.5</MinArmorPct>
			</li>
		</value>
	</Operation>

	<!-- ========== Diabolus ========== -->

	<Operation Class="PatchOperationAddModExtension">
		<xpath>Defs/ThingDef[defName="Mech_Diabolus"]</xpath>
		<value>
			<li Class="CombatExtended.RacePropertiesExtensionCE">
				<bodyShape>QuadrupedLow</bodyShape>
			</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Mech_Diabolus"]/statBases</xpath>
		<value>
			<ArmorRating_Heat>0.5</ArmorRating_Heat>
			<CarryWeight>75</CarryWeight>
			<CarryBulk>60</CarryBulk>
			<AimingAccuracy>1.3</AimingAccuracy>
			<ShootingAccuracyPawn>1.25</ShootingAccuracyPawn>
			<MeleeDodgeChance>0.03</MeleeDodgeChance>
			<MeleeCritChance>0.42</MeleeCritChance>
			<MeleeParryChance>0.64</MeleeParryChance>
			<MaxHitPoints>600</MaxHitPoints>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Mech_Diabolus"]/tools</xpath>
		<value>
			<tools>
				<li Class="CombatExtended.ToolCE">
					<label>head</label>
					<capacities>
						<li>Blunt</li>
					</capacities>
					<power>36</power>
					<cooldownTime>3.6</cooldownTime>
					<linkedBodyPartsGroup>HeadAttackTool</linkedBodyPartsGroup>
					<ensureLinkedBodyPartsGroupAlwaysUsable>true</ensureLinkedBodyPartsGroupAlwaysUsable>
					<armorPenetrationBlunt>16</armorPenetrationBlunt>
				</li>
			</tools>
		</value>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/ThingDef[defName="Mech_Diabolus"]/comps</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/ThingDef[defName="Mech_Diabolus"]</xpath>
			<value>
				<comps />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Mech_Diabolus"]/comps</xpath>
		<value>
			<li Class="CombatExtended.CompProperties_ArmorDurability">
				<Durability>4250</Durability>
				<Regenerates>true</Regenerates>
				<RegenInterval>1250</RegenInterval>
				<RegenValue>5</RegenValue>
				<Repairable>true</Repairable>
				<RepairIngredients>
					<Steel>5</Steel>
					<Plasteel>5</Plasteel>
				</RepairIngredients>
				<RepairTime>300</RepairTime>
				<RepairValue>200</RepairValue>
				<MinArmorPct>0.5</MinArmorPct>
			</li>
		</value>
	</Operation>

</Patch>