add drugfuel

This commit is contained in:
Cocopomel 2024-04-28 17:32:57 +09:00
parent f4ab35ded4
commit e31f1614d8
5 changed files with 326 additions and 154 deletions

View File

@ -5,6 +5,7 @@
<forcedHediffs> <forcedHediffs>
<li>PN_Immune_System</li> <li>PN_Immune_System</li>
<li>PN_Learning_Limit_System</li> <li>PN_Learning_Limit_System</li>
<li>PN_AutomatonFuel_Addiction</li>
</forcedHediffs> </forcedHediffs>
</AlienRace.AlienBackstoryDef> </AlienRace.AlienBackstoryDef>

View File

@ -317,7 +317,7 @@
</weaponList> </weaponList>
<foodList> <foodList>
<li>PN_AutomatonFuel</li>
</foodList> </foodList>
<whiteGeneTags> <whiteGeneTags>

View File

@ -0,0 +1,16 @@
<?xml version="1.0" encoding="utf-8" ?>
<Defs>
<DrugPolicyDef>
<defName>PN_fuelOneDrinkPerDay</defName>
<label>Automaton</label>
<entries>
<li>
<drug>PN_AutomatonFuel</drug>
<allowedForAddiction>true</allowedForAddiction>
<allowScheduled>true</allowScheduled>
<takeToInventory>1</takeToInventory>
<daysFrequency>1</daysFrequency>
</li>
</entries>
</DrugPolicyDef>
</Defs>

View File

@ -0,0 +1,130 @@
<?xml version="1.0" encoding="utf-8" ?>
<Defs>
<ThingCategoryDef>
<defName>PN_Fuel</defName>
<label>Automaton Fuel</label>
<parent>Drugs</parent>
<iconPath>UI/Icons/PNCT_PNFuel</iconPath>
</ThingCategoryDef>
<!--==================================== 오토마톤 연료 ====================================-->
<ThingDef ParentName="DrugPillBase">
<defName>PN_AutomatonFuel</defName>
<label>PnL fuel</label>
<description>Warning: Do not use on humans.\nThis fuel is for automaton only.\n\nThe fuel used by the automaton. Added a large amount of Psychite for mental stability.</description>
<tickerType>Normal</tickerType>
<graphicData>
<texPath>Things/Item/PNFuel</texPath>
<graphicClass>Graphic_StackCount</graphicClass>
<drawSize>1.0</drawSize>
</graphicData>
<uiIconForStackCount>1</uiIconForStackCount>
<stackLimit>150</stackLimit>
<rotatable>false</rotatable>
<statBases>
<MaxHitPoints>50</MaxHitPoints>
<MarketValue>6.1</MarketValue>
<Mass>0.05</Mass>
<Flammability>2.0</Flammability>
<DeteriorationRate>1.0</DeteriorationRate>
</statBases>
<techLevel>Ultra</techLevel>
<ingestible>
<drugCategory>Medical</drugCategory>
<baseIngestTicks>210</baseIngestTicks>
<ingestSound>Ingest_Drink</ingestSound>
<ingestHoldOffsetStanding>
<northDefault>
<offset>(0.18,0,0)</offset>
</northDefault>
</ingestHoldOffsetStanding>
<ingestCommandString>Drink {0}</ingestCommandString>
<ingestReportString>Drinking {0}.</ingestReportString>
<useEatingSpeedStat>false</useEatingSpeedStat>
<chairSearchRadius>25</chairSearchRadius>
<outcomeDoers>
</outcomeDoers>
</ingestible>
<comps>
<li Class="CompProperties_Drug">
<chemical>PN_Chemical_Fuel</chemical>
<addictiveness>0.000000001</addictiveness>
<needLevelOffset>0.20</needLevelOffset>
<listOrder>1028</listOrder>
</li>
<li Class="CompProperties_Explosive">
<explosiveRadius>1.1</explosiveRadius>
<explosiveDamageType>Flame</explosiveDamageType>
<explosiveExpandPerStackcount>0.037</explosiveExpandPerStackcount>
<startWickOnDamageTaken>
<li>Flame</li>
</startWickOnDamageTaken>
<startWickHitPointsPercent>0.333</startWickHitPointsPercent>
<preExplosionSpawnThingDef>Filth_Fuel</preExplosionSpawnThingDef>
<preExplosionSpawnChance>1</preExplosionSpawnChance>
<wickTicks>70~150</wickTicks>
</li>
</comps>
<tradeTags Inherit="false">
<li>PN_Fuel</li>
</tradeTags>
<tradeability>Buyable</tradeability>
<thingCategories Inherit="false">
<li>PN_Fuel</li>
</thingCategories>
</ThingDef>
<!--==================================== 오토마톤 연료 효과 ====================================-->
<ChemicalDef>
<defName>PN_Chemical_Fuel</defName>
<label>Automaton Fuel</label>
<addictionHediff>PN_AutomatonFuel_Addiction</addictionHediff>
<canBinge>false</canBinge>
<onGeneratedAddictedToleranceChance>0</onGeneratedAddictedToleranceChance>
<generateAddictionGenes>false</generateAddictionGenes>
</ChemicalDef>
<HediffDef ParentName="AddictionBase">
<defName>PN_AutomatonFuel_Addiction</defName>
<hediffClass>Hediff_Addiction</hediffClass>
<label>Automaton Fuel</label>
<description>A condition that requires PnL fuel.</description>
<defaultLabelColor>(222,90,90)</defaultLabelColor>
<causesNeed>PN_Need_Fuel</causesNeed>
<scenarioCanAdd>false</scenarioCanAdd>
<everCurableByItem>false</everCurableByItem>
<isBad>false</isBad>
<comps>
</comps>
<stages>
<li>
<label>stable</label>
</li>
<li>
<label>required</label>
<capMods>
<li>
<capacity>Consciousness</capacity>
<setMax>0.3</setMax>
</li>
<li>
<capacity>Moving</capacity>
<setMax>0.3</setMax>
</li>
<li>
<capacity>Sight</capacity>
<setMax>0.3</setMax>
</li>
<li>
<capacity>Manipulation</capacity>
<setMax>0.3</setMax>
</li>
</capMods>
<hungerRateFactor>8.0</hungerRateFactor>
</li>
</stages>
</HediffDef>
</Defs>

View File

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="utf-8" ?>
<Defs>
<NeedDef ParentName="DrugAddictionNeedBase">
<defName>PN_Need_Fuel</defName>
<needClass>Need_Chemical</needClass>
<label>Automaton Fuel</label>
<description>The amount of fuel used by the automaton. When the gauge reaches zero, The automaton will enter emergency power mode and become very slow.</description>
<listPriority>984</listPriority>
<fallPerDay>0.20</fallPerDay>
<freezeWhileSleeping>true</freezeWhileSleeping>
<showForCaravanMembers>true</showForCaravanMembers>
<major>true</major>
</NeedDef>
<!--<NeedDef>
<defName>PN_Need_Maintenance</defName>
<needClass>AutomataRace.Need_Maintenance</needClass>
<label>Maintenance</label>
<description>The maintenance status of the automaton.\n\nIf it is low, it will cause malfunction.\n\nMaintenance is required every year (60 rimworld days).</description>
<onlyIfCausedByHediff>true</onlyIfCausedByHediff>
<listPriority>985</listPriority>
<fallPerDay>0.01333</fallPerDay>
<showForCaravanMembers>true</showForCaravanMembers>
</NeedDef>-->
</Defs>