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

	<!-- ==================== Ammo ========================== -->

	<ThingDef Class="CombatExtended.AmmoDef" Name="AmmoBase" Abstract="True">
		<thingClass>CombatExtended.AmmoThing</thingClass>
		<label>unspecified ammunition</label>
		<category>Item</category>
		<resourceReadoutPriority>Middle</resourceReadoutPriority>
		<useHitPoints>true</useHitPoints>
		<statBases>
			<MaxHitPoints>100</MaxHitPoints>
			<Beauty>-5</Beauty>
			<Flammability>1</Flammability>
			<DeteriorationRate>2</DeteriorationRate>
		</statBases>
		<selectable>true</selectable>
		<altitudeLayer>Item</altitudeLayer>
		<stackLimit>5000</stackLimit>
		<soundInteract>Metal_Drop</soundInteract>
		<soundDrop>Metal_Drop</soundDrop>
		<menuHidden>True</menuHidden><!-- Toggled by AmmoInjector.cs -->
		<destroyOnDrop>True</destroyOnDrop><!-- Toggled by AmmoInjector.cs -->
		<comps>
			<li Class="CompProperties_Forbiddable" />
		</comps>
		<alwaysHaulable>true</alwaysHaulable>
		<drawGUIOverlay>true</drawGUIOverlay>
		<rotatable>false</rotatable>
		<pathCost>15</pathCost>
		<tradeTags>
			<li>CE_AmmoInjector</li>
			<li>CE_Ammo</li>
		</tradeTags>
		<tradeability>None</tradeability>
		<tickerType>Normal</tickerType>
		<cookOffSpeed>0.2</cookOffSpeed>
		<cookOffFlashScale>10</cookOffFlashScale>
		<cookOffSound>Shot_AssaultRifle</cookOffSound>
		<cookOffTailSound>GunTail_Medium</cookOffTailSound>
		<techLevel>Industrial</techLevel>
	</ThingDef>

	<ThingDef Class="CombatExtended.AmmoDef" Name="SmallAmmoBase" ParentName="AmmoBase" Abstract="True">
		<smallVolume>true</smallVolume>
		<statBases>
			<MaxHitPoints>75</MaxHitPoints>
		</statBases>
	</ThingDef>

	<ThingDef Class="CombatExtended.AmmoDef" Name="NeolithicAmmoBase" ParentName="AmmoBase" Abstract="True">
		<techLevel>Neolithic</techLevel>
	</ThingDef>

	<ThingDef Class="CombatExtended.AmmoDef" Name="SpacerSmallAmmoBase" ParentName="SmallAmmoBase" Abstract="True">
		<techLevel>Spacer</techLevel>
	</ThingDef>

	<ThingDef Class="CombatExtended.AmmoDef" Name="SpacerAmmoBase" ParentName="AmmoBase" Abstract="True">
		<techLevel>Spacer</techLevel>
	</ThingDef>

	<ThingDef Class="CombatExtended.AmmoDef" Name="SpacerMediumAmmoBase" ParentName="AmmoBase" Abstract="True">
		<techLevel>Spacer</techLevel>
		<tradeTags Inherit="False">
			<li>CE_AmmoInjector</li>
			<li>CE_MediumAmmo</li>
		</tradeTags>
	</ThingDef>

	<ThingDef Class="CombatExtended.AmmoDef" Name="MediumAmmoBase" ParentName="AmmoBase" Abstract="True">
		<tradeTags Inherit="False">
			<li>CE_AmmoInjector</li>
			<li>CE_MediumAmmo</li>
		</tradeTags>
	</ThingDef>

	<ThingDef Class="CombatExtended.AmmoDef" Name="HeavyAmmoBase" ParentName="AmmoBase" Abstract="True">
		<tradeTags Inherit="False">
			<li>CE_AmmoInjector</li>
			<li>CE_HeavyAmmo</li>
		</tradeTags>
	</ThingDef>

	<!-- ================== Projectiles ================== -->

	<ThingDef Class="CombatExtended.AmmoDef" Name="BaseBulletCE" ParentName="BaseBullet" Abstract="True">
		<thingClass>CombatExtended.BulletCE</thingClass>
		<projectile Class="CombatExtended.ProjectilePropertiesCE">
			<explosionDamageFalloff>true</explosionDamageFalloff>
		</projectile>
		<comps>
		<li Class="CombatExtended.CompProperties_CIWSImpactHandler">
			<compClass>CombatExtended.CompCIWSImpactHandler_Projectile</compClass>
		</li>
		</comps>
	</ThingDef>

	<ThingDef Class="CombatExtended.AmmoDef" Name="BaseFragment" ParentName="BaseBulletCE" Abstract="True">
		<projectile Class="CombatExtended.ProjectilePropertiesCE">
			<alwaysFreeIntercept>true</alwaysFreeIntercept>
		</projectile>
	</ThingDef>

	<ThingDef Name="BaseExplosiveBullet" ParentName="BaseBulletCE" Abstract="True">
		<projectile Class="CombatExtended.ProjectilePropertiesCE">
			<suppressionFactor>3.0</suppressionFactor>
			<dangerFactor>2.0</dangerFactor>
		</projectile>
	</ThingDef>

	<!-- ==================== Recipes ========================== -->

	<RecipeDef Name="AmmoRecipeBase" Abstract="true">
		<workSpeedStat>GeneralLaborSpeed</workSpeedStat>
		<effectWorking>Cook</effectWorking>
		<soundWorking>Recipe_Machining</soundWorking>
		<allowMixingIngredients>true</allowMixingIngredients>
		<workAmount>10000</workAmount>
		<workSkill>Crafting</workSkill>
		<workSkillLearnFactor>0.5</workSkillLearnFactor>
		<targetCountAdjustment>20</targetCountAdjustment>
		<recipeUsers>
			<!-- Need an empty list here or the ammo injector will throw a null ref exception -->
		</recipeUsers>
		<conceptLearned>CE_AmmoCrafting</conceptLearned>
		<unfinishedThingDef>UnfinishedAmmo</unfinishedThingDef>
	</RecipeDef>

	<RecipeDef Name="AdvancedAmmoRecipeBase" ParentName="AmmoRecipeBase" Abstract="true">
		<researchPrerequisite>CE_AdvancedAmmo</researchPrerequisite>
		<skillRequirements>
			<Crafting>6</Crafting>
		</skillRequirements>
	</RecipeDef>

	<RecipeDef Name="ArtilleryAmmoRecipeBase" ParentName="AmmoRecipeBase" Abstract="true">
		<researchPrerequisite>Mortars</researchPrerequisite>
		<skillRequirements>
			<Crafting>4</Crafting>
		</skillRequirements>
	</RecipeDef>

	<RecipeDef Name="LauncherAmmoRecipeBase" ParentName="AmmoRecipeBase" Abstract="true">
		<researchPrerequisite>CE_Launchers</researchPrerequisite>
		<skillRequirements>
			<Crafting>4</Crafting>
		</skillRequirements>
	</RecipeDef>

  	<RecipeDef Name="AdvancedLauncherAmmoRecipeBase" ParentName="AmmoRecipeBase" Abstract="true">
		<researchPrerequisite>CE_AdvancedLaunchers</researchPrerequisite>
		<skillRequirements>
			<Crafting>6</Crafting>
		</skillRequirements>
	</RecipeDef>
  
	<RecipeDef Name="CannonAmmoRecipeBase" ParentName="AmmoRecipeBase" Abstract="true">
		<researchPrerequisite>CE_TurretHeavyWeapons</researchPrerequisite>
		<skillRequirements>
			<Crafting>4</Crafting>
		</skillRequirements>
	</RecipeDef>

	<RecipeDef Name="ChargeAmmoRecipeBase" ParentName="AmmoRecipeBase" Abstract="true">
		<researchPrerequisite>ChargedShot</researchPrerequisite>
		<skillRequirements>
			<Crafting>7</Crafting>
		</skillRequirements>
	</RecipeDef>

	<RecipeDef Name="AmmoRecipeNeolithicBase" Abstract="true">
		<workSpeedStat>GeneralLaborSpeed</workSpeedStat>
		<effectWorking>Cook</effectWorking>
		<soundWorking>Recipe_Machining</soundWorking>
		<allowMixingIngredients>true</allowMixingIngredients>
		<workAmount>2000</workAmount>
		<workSkill>Crafting</workSkill>
		<workSkillLearnFactor>0.5</workSkillLearnFactor>		
		<targetCountAdjustment>20</targetCountAdjustment>
		<unfinishedThingDef>UnfinishedArrows</unfinishedThingDef>
	</RecipeDef>

	<!-- Base for hand grenades -->
	<RecipeDef ParentName="AmmoRecipeBase" Name="GrenadeRecipeBase" Abstract="true">
		<recipeUsers>
			<li>TableMachining</li>
		</recipeUsers>
	</RecipeDef>

</Defs>