Quote from: 1000101 on August 07, 2016, 02:27:39 PM
We'd need to see the code for your thought worker to help you with detecting the presence/absence of a particular pawn class (thingDef).
"Thoughtworker_ColonyHasNoAlien" isn't referring to anything at the moment, I just use it as a placeholder for when I find an actual line of code to refer to.
Did you need this?
Code Select
<?xml version="1.0" encoding="utf-8" ?>
<ThingDefs>
<!-- ============================ Alien ========================== -->
<ThingDef ParentName="BasePawn">
<defName>Alien</defName>
<label>alien</label>
<description>A new sentient lifeform that has unceremoniously made contact with humans across the galaxy. Very little is known about their physiology.</description>
<uiIconPath>Things/Pawn/Humanlike/UI/IconHuman</uiIconPath>
<statBases>
<MarketValue>4750</MarketValue>
<MoveSpeed>4.61</MoveSpeed>
<Flammability>1.0</Flammability>
<ComfyTemperatureMin>8</ComfyTemperatureMin>
<ComfyTemperatureMax>28</ComfyTemperatureMax>
<LeatherAmount>20</LeatherAmount>
</statBases>
<verbs>
<li>
<verbClass>Verb_MeleeAttack</verbClass>
<defaultCooldownTicks>100</defaultCooldownTicks>
<meleeDamageBaseAmount>7</meleeDamageBaseAmount>
<meleeDamageDef>Blunt</meleeDamageDef>
<linkedBodyPartsGroup>LeftHand</linkedBodyPartsGroup>
</li>
<li>
<verbClass>Verb_MeleeAttack</verbClass>
<defaultCooldownTicks>100</defaultCooldownTicks>
<meleeDamageBaseAmount>7</meleeDamageBaseAmount>
<meleeDamageDef>Blunt</meleeDamageDef>
<linkedBodyPartsGroup>RightHand</linkedBodyPartsGroup>
</li>
</verbs>
<race>
<thinkTreeMain>Humanlike</thinkTreeMain>
<thinkTreeConstant>HumanlikeConstant</thinkTreeConstant>
<intelligence>Humanlike</intelligence>
<makesFootprints>true</makesFootprints>
<lifeExpectancy>80</lifeExpectancy>
<leatherColor>(180,230,190)</leatherColor>
<leatherCommonalityFactor>0.01</leatherCommonalityFactor>
<leatherInsulation>0.70</leatherInsulation>
<leatherMarketValue>30</leatherMarketValue>
<nameCategory>HumanStandard</nameCategory>
<body>Human</body>
<baseBodySize>1</baseBodySize>
<baseHealthScale>1</baseHealthScale>
<foodType>OmnivoreHuman</foodType>
<gestationPeriodDays>45</gestationPeriodDays>
<litterSizeCurve>
<points>
<li>(0.5, 0)</li>
<li>(1, 1)</li>
<li>(1.01, 0.02)</li>
<li>(3.5, 0)</li>
</points>
</litterSizeCurve>
<lifeStageAges>
<li>
<def>HumanlikeBaby</def>
<minAge>0</minAge>
</li>
<li>
<def>HumanlikeToddler</def>
<minAge>1.2</minAge>
</li>
<li>
<def>HumanlikeChild</def>
<minAge>4</minAge>
</li>
<li>
<def>HumanlikeTeenager</def>
<minAge>13</minAge>
</li>
<li>
<def>HumanlikeAdult</def>
<minAge>18</minAge>
</li>
</lifeStageAges>
<soundMeleeHitPawn>Pawn_Melee_Punch_HitPawn</soundMeleeHitPawn>
<soundMeleeHitBuilding>Pawn_Melee_Punch_HitBuilding</soundMeleeHitBuilding>
<soundMeleeMiss>Pawn_Melee_Punch_Miss</soundMeleeMiss>
<specialshadowData>
<volume>(0.3, 0.8, 0.4)</volume>
<offset>(0,0,-0.3)</offset>
</specialshadowData>
<ageGenerationCurve>
<points>
<li>(14,0)</li>
<li>(16,100)</li>
<li>(50,100)</li>
<li>(60,30)</li>
<li>(70,18)</li>
<li>(80,10)</li>
<li>(90,3)</li>
<li>(100,0)</li>
</points>
</ageGenerationCurve>
<hediffGiverSets>
<li>OrganicStandard</li>
</hediffGiverSets>
</race>
<recipes>
<li>InstallPowerClaw</li>
<li>InstallScytherBlade</li>
<li>InstallBionicEye</li>
<li>InstallBionicArm</li>
<li>InstallBionicLeg</li>
<li>InstallSimpleProstheticArm</li>
<li>InstallSimpleProstheticLeg</li>
<li>InstallPegLeg</li>
<li>InstallDenture</li>
<li>InstallJoywire</li>
<li>InstallPainstopper</li>
<li>InstallNaturalHeart</li>
<li>InstallNaturalLung</li>
<li>InstallNaturalKidney</li>
<li>InstallNaturalLiver</li>
<li>ExciseCarcinoma</li>
<li>RemoveBodyPart</li>
<li>Euthanize</li>
</recipes>
</ThingDef>
</ThingDefs>