<?xml version="1.0" encoding="utf-8" ?>
<Defs>
  <!--==================================== 미완성 오토마톤 ====================================-->
  <ThingDef ParentName="UnfinishedBase">
    <defName>UnfinishedAutomaton</defName>
    <label>unfinished automaton</label>
    <description>An unfinished automaton.</description>
    <statBases>
      <Flammability>0.5</Flammability>
    </statBases>
    <graphicData>
      <texPath>Things/Item/Unfinished/UnfinishedTechArmor</texPath>
      <graphicClass>Graphic_Single</graphicClass>
    </graphicData>
    <stuffCategories Inherit="false" />
  </ThingDef>

  <!--==================================== 오토마톤 가죽 ====================================-->
  <ThingDef ParentName="LeatherBase">
    <defName>Leather_Automaton</defName>
    <label>automaton skin</label>
    <description>leather made for automaton production. looks like human leather.</description>
    <graphicData>
      <color>(255,240,227)</color>
    </graphicData>
    <statBases>
      <MarketValue>4.2</MarketValue>
      <StuffPower_Armor_Sharp>0.64</StuffPower_Armor_Sharp>
      <StuffPower_Insulation_Cold>12</StuffPower_Insulation_Cold>
      <StuffPower_Insulation_Heat>12</StuffPower_Insulation_Heat>
    </statBases>
    <stuffProps>
      <color>(255,240,227)</color>
      <commonality>0.0025</commonality>
    </stuffProps>
  </ThingDef>

  <!--==================================== 생체 중추신경 ====================================-->
  <ThingDef ParentName="BodyPartNaturalBase">
    <defName>PN_Brain</defName>
    <label>central nervous</label>
    <description>A biological human central nervous.</description>
    <statBases>
      <MarketValue>500</MarketValue>
      <Mass>1</Mass>
    </statBases>
    <comps>
      <li Class="CompProperties_Lifespan">
        <lifespanTicks>240000</lifespanTicks>
        <expireEffect>RaisedRock_Collapse</expireEffect>
      </li>
    </comps>
    <tickerType>Normal</tickerType>
  </ThingDef>

  <!--==================================== 수리키트 ====================================-->
  <ThingCategoryDef>
    <defName>PNKit</defName>
    <label>Automaton kit</label>
    <parent>Manufactured</parent>
    <resourceReadoutRoot>true</resourceReadoutRoot>
    <iconPath>UI/Icons/ThingCategories/Medicine</iconPath>
  </ThingCategoryDef>

  <ThingDef ParentName="ResourceBase">
    <defName>PN_RepairKit</defName>
    <label>automaton repair kit</label>
    <description>test repair kit</description>
    <graphicData>
      <texPath>Things/Item/Special/MechSerumHealer</texPath>
      <graphicClass>Graphic_Single</graphicClass>
      <color>(154,124,104)</color>
    </graphicData>
    <stackLimit>10</stackLimit>
    <healthAffectsPrice>false</healthAffectsPrice>
    <statBases>
      <MarketValue>18</MarketValue>
      <Mass>0.50</Mass>
      <Flammability>0.7</Flammability>
      <WorkToMake>350</WorkToMake>
    </statBases>
    <thingCategories>
      <li>PNKit</li>
    </thingCategories>
    <tradeability>Sellable</tradeability>
    <comps>

    </comps>
  </ThingDef>

  <!--==================================== 자가 수리 키트 ====================================-->
  <ThingDef ParentName="MechSerumBase">
    <defName>PN_SelfRepairKit</defName>
    <label>automaton self repair kit</label>
    <description>test repair kit</description>
    <graphicData>
      <texPath>Things/Item/Special/MechSerumHealer</texPath>
      <graphicClass>Graphic_Single</graphicClass>
      <color>(154,124,104)</color>
    </graphicData>
    <stackLimit>10</stackLimit>
    <statBases>
      <MarketValue>18</MarketValue>
      <Mass>0.50</Mass>
      <Flammability>0.7</Flammability>
      <WorkToMake>700</WorkToMake>
    </statBases>
    <thingCategories>
      <li>PNKit</li>
    </thingCategories>
    <tradeability>Sellable</tradeability>
    <comps>
      <li Class="CompProperties_Usable">
        <useJob>UseItem</useJob>
        <useLabel>Use repair kit</useLabel>
        <useDuration>600</useDuration>
      </li>
      <li Class="AutomataRace.CompProperties_UseEffectRepairKit">
        <thingDefs>
          <li>Paniel_Race</li>
        </thingDefs>
        <blockUnnecessaryUse>true</blockUnnecessaryUse>
      </li>
      <li Class="CompProperties_UseEffect">
        <compClass>CompUseEffect_DestroySelf</compClass>
      </li>
    </comps>
  </ThingDef>

  <RecipeDef>
    <defName>PN_AdministerSelfRepairKit</defName>
    <label>administer self repair kit</label>
    <description>Administer a self repair kit.</description>
    <workerClass>Recipe_AdministerUsableItem</workerClass>
    <jobString>Administering self repair kit.</jobString>
    <targetsBodyPart>false</targetsBodyPart>
    <anesthetize>false</anesthetize>
    <workAmount>600</workAmount>
    <dontShowIfAnyIngredientMissing>true</dontShowIfAnyIngredientMissing>
    <surgerySuccessChanceFactor>99999</surgerySuccessChanceFactor>
    <ingredients>
      <li>
        <filter>
          <thingDefs>
            <li>PN_SelfRepairKit</li>
          </thingDefs>
        </filter>
        <count>1</count>
      </li>
    </ingredients>
    <fixedIngredientFilter>
      <thingDefs>
        <li>PN_SelfRepairKit</li>
      </thingDefs>
    </fixedIngredientFilter>
    <recipeUsers>
      <li>Paniel_Race</li>
    </recipeUsers>
  </RecipeDef>

  <!--==================================== 오토마톤 뉴로링크 ====================================-->
  <ThingDef>
    <defName>PN_PsychicAmplifier</defName>
    <label>automaton psylink neuroformer</label>
    <description>A consumable archotech-created device that forms or upgrades a psylink in the user's mind.\n\nThe user presses the device over the eyes, where it links to the brain directly and restructures part of it. Afterwards, the device disintegrates into worthless ash.</description>
    <descriptionHyperlinks>
      <HediffDef>PsychicAmplifier</HediffDef>
    </descriptionHyperlinks>
    <thingClass>ThingWithComps</thingClass>
    <category>Item</category>
    <techLevel>Archotech</techLevel>
    <useHitPoints>true</useHitPoints>
    <pathCost>14</pathCost>
    <selectable>true</selectable>
    <altitudeLayer>Item</altitudeLayer>
    <tickerType>Never</tickerType>
    <alwaysHaulable>true</alwaysHaulable>
    <resourceReadoutPriority>Middle</resourceReadoutPriority>
    <thingCategories>
      <li>BodyPartsArchotech</li>
    </thingCategories>
    <statBases>
      <MaxHitPoints>100</MaxHitPoints>
      <Beauty>-4</Beauty>
      <Mass>1</Mass>
      <MarketValue>2600</MarketValue>
      <DeteriorationRate>0</DeteriorationRate>
    </statBases>
    <graphicData>
      <texPath>Things/Item/Special/PsylinkNeuroformer</texPath>
      <graphicClass>Graphic_Single</graphicClass>
    </graphicData>
    <tradeTags>
      <li>PsylinkNeuroformer</li>
    </tradeTags>
    <comps>
      <li Class="CompProperties_Usable">
        <compClass>CompUsableImplant</compClass>
        <useJob>UseItem</useJob>
        <useLabel>Use neuroformer to form psylink</useLabel>
      </li>
      <li Class="CompProperties_UseEffectInstallImplant">
        <hediffDef>PsychicAmplifier</hediffDef>
        <bodyPart>PNBrain</bodyPart>
        <canUpgrade>true</canUpgrade>
      </li>
      <li Class="CompProperties_UseEffectPlaySound">
        <soundOnUsed>PsyAmpInstalled</soundOnUsed>
      </li>
      <li Class="CompProperties_UseEffect">
        <compClass>CompUseEffect_DestroySelf</compClass>
      </li>
      <li Class="CompProperties_Forbiddable"/>
    </comps>
  </ThingDef>
</Defs>