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

	<!-- ==================== VGE_Astropede ==================== -->

	<!-- ========== Add groups entry if it doesn't exist already ========== -->

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/parts/li[def="SightSensor"]/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/parts/li[def="SightSensor"]</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/parts/li[def="HearingSensor"]/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/parts/li[def="HearingSensor"]</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/parts/li[def="SmellSensor"]/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/parts/li[def="SmellSensor"]</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="MechanicalCentipedeBodyFourthRing"]/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="MechanicalCentipedeBodyFourthRing"]</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="MechanicalCentipedeBodyFourthRing"]/parts/li[def="MechanicalCentipedeBodyFifthRing"]/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="MechanicalCentipedeBodyFourthRing"]/parts/li[def="MechanicalCentipedeBodyFifthRing"]</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>

	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="MechanicalCentipedeBodyFourthRing"]/parts/li[def="MechanicalCentipedeBodyFifthRing"]/parts/li[def="MechanicalCentipedeBodySixthRing"]/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="MechanicalCentipedeBodyFourthRing"]/parts/li[def="MechanicalCentipedeBodyFifthRing"]/parts/li[def="MechanicalCentipedeBodySixthRing"]</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>
	
	<Operation Class="PatchOperationConditional">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="VGE_MechanicalTail"]/groups</xpath>
		<nomatch Class="PatchOperationAdd">
			<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="VGE_MechanicalTail"]</xpath>
			<value>
				<groups />
			</value>
		</nomatch>
	</Operation>


	<!-- ========== Add armor coverage ========== -->

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/parts/li[def="SightSensor"]/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/parts/li[def="HearingSensor"]/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalHead"]/parts/li[def="SmellSensor"]/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="MechanicalCentipedeBodyFourthRing"]/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="MechanicalCentipedeBodyFourthRing"]/parts/li[def="MechanicalCentipedeBodyFifthRing"]/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="MechanicalCentipedeBodyFourthRing"]/parts/li[def="MechanicalCentipedeBodyFifthRing"]/parts/li[def="MechanicalCentipedeBodySixthRing"]/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<Operation Class="PatchOperationAdd">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="VGE_MechanicalTail"]/groups</xpath>
		<value>
			<li>CoveredByNaturalArmor</li>
		</value>
	</Operation>

	<!-- ========== Modify coverage ========== -->

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="Reactor"]/coverage</xpath>
		<value>
			<coverage>0.15</coverage>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="FluidReprocessor"]/coverage</xpath>
		<value>
			<coverage>0.1</coverage>
		</value>
	</Operation>

	<Operation Class="PatchOperationReplace">
		<xpath>Defs/BodyDef[defName="VGE_Astropede"]/corePart/parts/li[def="MechanicalCentipedeBodySecondRing"]/parts/li[def="MechanicalCentipedeBodyThirdRing"]/parts/li[def="MechanicalCentipedeBodyFourthRing"]/parts/li[def="FluidReprocessor"]/coverage</xpath>
		<value>
			<coverage>0.12</coverage>
		</value>
	</Operation>

</Patch>