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

	<!-- ===== Add Bodypart Groups and Layers ===== -->
	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="EoD_VanguardArmor"]/apparel/bodyPartGroups</xpath>
		<value>
			<li>Hands</li>
			<li>Feet</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="EoD_VanguardHelmet"]/apparel/layers</xpath>
		<value>
			<li>OnHead</li>
			<li>StrappedHead</li>
		</value>
	</Operation>

	<!-- ===== Add Costlist ===== -->
	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="EoD_VanguardArmor"]/costList</xpath>
		<value>
			<DevilstrandCloth>100</DevilstrandCloth>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="EoD_VanguardHelmet"]/costList</xpath>
		<value>
			<DevilstrandCloth>40</DevilstrandCloth>
		</value>
	</Operation>

	<!-- ===== Vanguard Armor ===== -->
	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="EoD_VanguardArmor"]/statBases</xpath>
		<value>
			<Bulk>85</Bulk>
			<WornBulk>12.8</WornBulk>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="EoD_VanguardArmor"]/statBases/MaxHitPoints</xpath>
		<value>
			<MaxHitPoints>450</MaxHitPoints>
		</value>
	</Operation>

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

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="EoD_VanguardArmor"]/statBases/Flammability</xpath>
		<value>
			<Flammability>0.15</Flammability>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="EoD_VanguardArmor"]/equippedStatOffsets</xpath>
		<value>
			<CarryWeight>65</CarryWeight>
			<CarryBulk>8</CarryBulk>
			<ShootingAccuracyPawn>0.10</ShootingAccuracyPawn>
			<ToxicEnvironmentResistance>0.50</ToxicEnvironmentResistance>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="EoD_VanguardArmor"]/equippedStatOffsets/MoveSpeed</xpath>
		<value>
			<MoveSpeed>0.4</MoveSpeed>
		</value>
	</Operation>

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

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

	<Operation Class="PatchOperationAddModExtension">
		<xpath>Defs/ThingDef[defName="EoD_VanguardArmor"]</xpath>
		<value>
			<li Class="CombatExtended.PartialArmorExt">
				<stats>
					<li>
						<ArmorRating_Sharp>0.70</ArmorRating_Sharp>
						<parts>
							<li>Neck</li>
							<li>Hand</li>
						</parts>
					</li>
					<li>
						<ArmorRating_Blunt>0.70</ArmorRating_Blunt>
						<parts>
							<li>Neck</li>
							<li>Hand</li>
						</parts>
					</li>
					<li>
						<ArmorRating_Sharp>0.90</ArmorRating_Sharp>
						<parts>
							<li>Leg</li>
						</parts>
					</li>
					<li>
						<ArmorRating_Blunt>0.90</ArmorRating_Blunt>
						<parts>
							<li>Leg</li>
						</parts>
					</li>
					<li>
						<ArmorRating_Sharp>0.80</ArmorRating_Sharp>
						<parts>
							<li>Arm</li>
						</parts>
					</li>
					<li>
						<ArmorRating_Blunt>0.80</ArmorRating_Blunt>
						<parts>
							<li>Arm</li>
						</parts>
					</li>
				</stats>
			</li>
		</value>
	</Operation>

	<!-- ===== Vanguard Helmet ===== -->
	<Operation Class="PatchOperationAddModExtension">
		<xpath>Defs/ThingDef[defName="EoD_VanguardHelmet"]</xpath>
		<value>
			<li Class="CombatExtended.ApparelDefExtension">
				<isRadioPack>true</isRadioPack>
			</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="EoD_VanguardHelmet"]/statBases</xpath>
		<value>
			<Bulk>4</Bulk>
			<WornBulk>1</WornBulk>
			<NightVisionEfficiency_Apparel>0.65</NightVisionEfficiency_Apparel>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="EoD_VanguardHelmet"]/statBases/MaxHitPoints</xpath>
		<value>
			<MaxHitPoints>210</MaxHitPoints>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/ThingDef[defName="EoD_VanguardHelmet"]/statBases/Flammability</xpath>
		<value>
			<Flammability>0.2</Flammability>
		</value>
	</Operation>

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

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/ThingDef[defName="EoD_VanguardHelmet"]/equippedStatOffsets</xpath>
		<value>
			<AimingAccuracy>0.15</AimingAccuracy>
			<SmokeSensitivity>-1</SmokeSensitivity>
			<ToxicEnvironmentResistance>0.50</ToxicEnvironmentResistance>
		</value>
	</Operation>

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

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

	<Operation Class="PatchOperationAddModExtension">
		<xpath>Defs/ThingDef[defName="EoD_VanguardHelmet"]</xpath>
		<value>
			<li Class="CombatExtended.PartialArmorExt">
				<stats>
					<li>
						<ArmorRating_Sharp>0.80</ArmorRating_Sharp>
						<parts>
							<li>Eye</li>
						</parts>
					</li>
					<li>
						<ArmorRating_Blunt>0.80</ArmorRating_Blunt>
						<parts>
							<li>Eye</li>
						</parts>
					</li>
				</stats>
			</li>
		</value>
	</Operation>

</Patch>