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

  <!--========== Remove Hemp Cloth ==========-->
	
	<Operation Class="PatchOperationSequence">
	    <success>Always</success>
		<operations>
            <li Class="ModCheck.FindFile">
                <modName>VGP Garden Fabrics</modName>
                <file>Items_cloth.xml</file>
            </li>
			<li Class="PatchOperationRemove">
				<xpath>Defs/ThingDef[defName = "HempCloth"]</xpath>
			</li>
		</operations>
	</Operation>

	<Operation Class="PatchOperationSequence"> 
	    <success>Always</success>
		<operations>
            <li Class="ModCheck.FindFile">
                <modName>VGP Garden Fabrics</modName>
                <file>Recipes_loom.xml</file>
            </li>
			<li Class="PatchOperationRemove">
				<xpath>Defs/RecipeDef[defName = "MakeHempCloth"]</xpath>
			</li>
		</operations>
	</Operation>

	<Operation Class="PatchOperationSequence"> 
	    <success>Always</success>
		<operations>
            <li Class="ModCheck.FindFile">
                <modName>VGP Garden Fabrics</modName>
                <file>Recipes_loom.xml</file>
            </li>
			<li Class="PatchOperationReplace">
				<xpath>Defs/RecipeDef[defName = "Makeblendedcloth"]/ingredients/li/filter/thingDefs</xpath>
				<value>
					<thingDefs>
						<li>Synthread</li>
						<li>DevilstrandCloth</li>
						<li>Hyperweave</li>
						<li>HempFabric</li>
						<li>DevilsleafFabric</li>
						<li>Flaxcloth</li>
					</thingDefs>
				</value>
			</li>
			<li Class="PatchOperationReplace">
				<xpath>Defs/RecipeDef[defName = "Makeblendedcloth"]/fixedIngredientFilter/thingDefs</xpath>
				<value>
					<thingDefs>
						<li>Synthread</li>
						<li>DevilstrandCloth</li>
						<li>Hyperweave</li>
						<li>HempFabric</li>
						<li>DevilsleafFabric</li>
						<li>Flaxcloth</li>
					</thingDefs>
				</value>
			</li>
		</operations>
	</Operation>
	
  <!--========== Add Fabrics To Loom ==========-->
	
	<Operation Class="PatchOperationSequence">
	    <success>Always</success>
		<operations>
			<li Class="ModCheck.isModLoaded">
				<modName>VGP Garden Fabrics</modName>
				<yourMod>Smokeleaf Industry</yourMod>
			</li>
            <li Class="ModCheck.FindFile">
                <modName>Smokeleaf Industry</modName>
                <file>MSI_Recipes_Production.xml</file>
            </li>
			<li Class="PatchOperationReplace">
				<xpath>Defs/RecipeDef[defName = "CraftHempFibers"]/recipeUsers</xpath>
				<value>
					<recipeUsers>
						<li>TableLoom</li>
						<li>TableElecLoom</li>
					</recipeUsers>
				</value>
			</li>
			<li Class="PatchOperationReplace">
				<xpath>Defs/RecipeDef[defName = "BulkCraftHempFibers"]/recipeUsers</xpath>
				<value>
					<recipeUsers>
						<li>TableLoom</li>
						<li>TableElecLoom</li>
					</recipeUsers>
				</value>
			</li>
			<li Class="PatchOperationReplace">
				<xpath>Defs/RecipeDef[defName = "CraftDevilsleafFibers"]/recipeUsers</xpath>
				<value>
					<recipeUsers>
						<li>TableLoom</li>
						<li>TableElecLoom</li>
					</recipeUsers>
				</value>
			</li>
			<li Class="PatchOperationReplace">
				<xpath>Defs/RecipeDef[defName = "BulkCraftDevilsleafFibers"]/recipeUsers</xpath>
				<value>
					<recipeUsers>
						<li>TableLoom</li>
						<li>TableElecLoom</li>
					</recipeUsers>
				</value>
			</li>
		</operations>
	</Operation>
	
</Patch>