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

	<Operation Class="PatchOperationFindMod">
		<mods>
			<li>Vehicle Framework</li>
		</mods>
		<match Class="PatchOperationSequence">
			<operations>

				<!--===== Heavy Bolter =====-->

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyBolter"]/projectile</xpath>
					<value>
						<projectile>Bullet_Bolter998_Standard</projectile>
					</value>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyBolter"]/reloadTimer</xpath>
					<value>
						<reloadTimer>7.8</reloadTimer>
					</value>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyBolter"]/warmUpTimer</xpath>
					<value>
						<warmUpTimer>2.3</warmUpTimer>
					</value>
				</li>

				<li Class="PatchOperationRemove">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyBolter"]/chargePerAmmoCount</xpath>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyBolter"]/genericAmmo</xpath>
					<value>
						<genericAmmo>false</genericAmmo>
					</value>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyBolter"]/maxRange</xpath>
					<value>
						<maxRange>62</maxRange>
					</value>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyBolter"]/ammunition/thingDefs</xpath>
					<value>
						<thingDefs>
							<li>Ammo_Bolter998_Standard</li>
							<li>Ammo_Bolter998_MetalStorm</li>
							<li>Ammo_Bolter998_Kraken</li>
							<li>Ammo_Bolter998_Inferno</li>
							<li>Ammo_Bolter998_Tempest</li>
						</thingDefs>
					</value>
				</li>

				<li Class="PatchOperationAddModExtension">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyBolter"]</xpath>
					<value>
						<li Class="Vehicles.CETurretDataDefModExtension">
							<ammoSet>AmmoSet_Bolter998</ammoSet>
							<shotHeight>1.5</shotHeight>
							<speed>229</speed>
							<sway>1.0</sway>
							<spread>0.01</spread>
						</li>
					</value>
				</li>

				<!--===== Heavy Flamer =====-->

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]/projectile</xpath>
					<value>
						<projectile>Bullet_Flamethrower_Prometheum</projectile>
					</value>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]/reloadTimer</xpath>
					<value>
						<reloadTimer>7.8</reloadTimer>
					</value>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]/warmUpTimer</xpath>
					<value>
						<warmUpTimer>1.3</warmUpTimer>
					</value>
				</li>

				<li Class="PatchOperationRemove">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]/chargePerAmmoCount</xpath>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]/genericAmmo</xpath>
					<value>
						<genericAmmo>false</genericAmmo>
					</value>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]/maxRange</xpath>
					<value>
						<maxRange>28</maxRange>
					</value>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]/magazineCapacity</xpath>
					<value>
						<magazineCapacity>120</magazineCapacity>
					</value>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]/fireModes</xpath>
					<value>
						<fireModes>
							<li>
								<shotsPerBurst>12</shotsPerBurst>
								<ticksBetweenShots>6</ticksBetweenShots>
								<ticksBetweenBursts>90</ticksBetweenBursts>
								<label>Auto</label>
								<texPath>UI/Gizmos/FireRate_Auto</texPath>
							</li>
						</fireModes>
					</value>
				</li>

				<li Class="PatchOperationAdd">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]</xpath>
					<value>
						<minRange>3</minRange>
					</value>
				</li>

				<li Class="PatchOperationReplace">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]/ammunition/thingDefs</xpath>
					<value>
						<thingDefs>
							<li>Ammo_Flamethrower_Napalm</li>
							<li>Ammo_Flamethrower_Prometheum</li>
							<li MayRequire="Ludeon.RimWorld.Anomaly">Ammo_Flamethrower_Bioferrite</li>
						</thingDefs>
					</value>
				</li>

				<li Class="PatchOperationAddModExtension">
					<xpath>Defs/Vehicles.VehicleTurretDef[defName="GW_Vehicle_HeavyFlamer"]</xpath>
					<value>
						<li Class="Vehicles.CETurretDataDefModExtension">
							<ammoSet>AmmoSet_Flamethrower</ammoSet>
							<shotHeight>1.5</shotHeight>
							<speed>20</speed>
							<sway>1.0</sway>
							<spread>6.0</spread>
						</li>
					</value>
				</li>			

			</operations>
		</match>
	</Operation>

</Patch>