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

	<!-- ===== Mecha Power Armor ===== -->
	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Apparel_MechaArmor_MechanoidBench"]/statBases/MaxHitPoints</xpath>
		<value>
			<Bulk>100</Bulk>
			<WornBulk>16</WornBulk>
			<MaxHitPoints>1000</MaxHitPoints>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Apparel_MechaArmor_MechanoidBench"]/statBases/Mass</xpath>
		<value>
			<Mass>47</Mass>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[@Name="ApparelMBBase"]/equippedStatOffsets</xpath>
		<value>
			<equippedStatOffsets>
				<CarryWeight>90</CarryWeight>
				<CarryBulk>13.5</CarryBulk>
				<ShootingAccuracyPawn>0.15</ShootingAccuracyPawn>
				<ToxicEnvironmentResistance>0.50</ToxicEnvironmentResistance>
			</equippedStatOffsets>
		</value>
	</Operation>

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

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

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[@Name="ApparelMBBase"]/apparel/bodyPartGroups</xpath>
		<value>
			<li>Hands</li>
			<li>Feet</li>
		</value>
	</Operation>

	<!-- == Increase Mecha Armor Cost == -->
	
	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Apparel_MechaArmor_MechanoidBench"]</xpath>
		<value>
			<costList Inherit="False">
				<MechanoidBench_MechaComponent>12</MechanoidBench_MechaComponent>
				<ComponentSpacer>6</ComponentSpacer>
				<Plasteel>210</Plasteel>
				<Chemfuel>40</Chemfuel>
				<Uranium>70</Uranium>
				<DevilstrandCloth>100</DevilstrandCloth>
			</costList>
		</value>
	</Operation>

	<!-- ===== Mecha Power Helmet ===== -->
	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Apparel_MechaHelmet_MechanoidBench"]/statBases/MaxHitPoints</xpath>
		<value>
			<Bulk>5</Bulk>
			<WornBulk>1</WornBulk>
			<MaxHitPoints>280</MaxHitPoints>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="Apparel_MechaHelmet_MechanoidBench"]/statBases/Mass</xpath>
		<value>
			<Mass>2.5</Mass>
		</value>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/ThingDef[defName="Apparel_MechaHelmet_MechanoidBench"]/apparel/immuneToToxGasExposure</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/ThingDef[defName="Apparel_MechaHelmet_MechanoidBench"]/apparel</xpath>
			<value>
				<immuneToToxGasExposure>true</immuneToToxGasExposure>
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Apparel_MechaHelmet_MechanoidBench"]</xpath>
		<value>
			<equippedStatOffsets>
				<AimingAccuracy>0.20</AimingAccuracy>
				<ToxicEnvironmentResistance>0.50</ToxicEnvironmentResistance>
				<SmokeSensitivity>-1</SmokeSensitivity>
				<NightVisionEfficiency_Apparel>0.6</NightVisionEfficiency_Apparel>
			</equippedStatOffsets>
		</value>
	</Operation>
	
	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="Apparel_MechaArmor_MechanoidBench"]</xpath>
		<value>
			<costList Inherit="False">
				<MechanoidBench_MechaComponent>6</MechanoidBench_MechaComponent>
				<ComponentSpacer>1</ComponentSpacer>
				<Plasteel>50</Plasteel>
				<Chemfuel>20</Chemfuel>
				<DevilstrandCloth>40</DevilstrandCloth>
			</costList>
		</value>
	</Operation>

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

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

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[@Name="ApparelMBHelmetBase"]/apparel/layers</xpath>
		<value>
			<li>OnHead</li>
			<li>StrappedHead</li>
		</value>
	</Operation>

</Patch>