1
This commit is contained in:
Binary file not shown.
140
1.6/1.6/Defs/HediffDefs/ARA_Hediffs_Incubator_Reward.xml
Normal file
140
1.6/1.6/Defs/HediffDefs/ARA_Hediffs_Incubator_Reward.xml
Normal file
@@ -0,0 +1,140 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
|
<Defs>
|
||||||
|
<HediffDef>
|
||||||
|
<defName>ARA_Incubator_1_Reward_Hediffs</defName>
|
||||||
|
<label>致密甲壳</label>
|
||||||
|
<description>该阿拉克涅督虫的甲壳比起常规虫族更加紧密,这使得她的甲壳获得了额外的防御力。\n\n由于良好的孵化质量,阿拉克涅督虫获得了这个有利突变。</description>
|
||||||
|
<hediffClass>HediffWithComps</hediffClass>
|
||||||
|
<isBad>false</isBad>
|
||||||
|
<defaultLabelColor>(0.3, 0.7, 0.2)</defaultLabelColor>
|
||||||
|
<scenarioCanAdd>true</scenarioCanAdd>
|
||||||
|
<stages>
|
||||||
|
<li>
|
||||||
|
<statOffsets>
|
||||||
|
<ArmorRating_Blunt>0.25</ArmorRating_Blunt>
|
||||||
|
<ArmorRating_Sharp>0.25</ArmorRating_Sharp>
|
||||||
|
</statOffsets>
|
||||||
|
</li>
|
||||||
|
</stages>
|
||||||
|
</HediffDef>
|
||||||
|
<HediffDef>
|
||||||
|
<defName>ARA_Incubator_2_Reward_Hediffs</defName>
|
||||||
|
<label>壳下阻燃脂</label>
|
||||||
|
<description>该阿拉克涅督虫的皮下脂肪由于有利突变,获得了阻燃效果。当虫族被火焰灼烧时,阻燃脂肪层会爆裂开以扑灭身上的火势。\n\n由于良好的孵化质量,阿拉克涅督虫获得了这个有利突变。</description>
|
||||||
|
<hediffClass>HediffWithComps</hediffClass>
|
||||||
|
<isBad>false</isBad>
|
||||||
|
<defaultLabelColor>(0.3, 0.7, 0.2)</defaultLabelColor>
|
||||||
|
<scenarioCanAdd>true</scenarioCanAdd>
|
||||||
|
<stages>
|
||||||
|
<li>
|
||||||
|
<statOffsets>
|
||||||
|
<ArmorRating_Heat>0.5</ArmorRating_Heat>
|
||||||
|
</statOffsets>
|
||||||
|
<statFactors>
|
||||||
|
<Flammability>0</Flammability>
|
||||||
|
</statFactors>
|
||||||
|
</li>
|
||||||
|
</stages>
|
||||||
|
</HediffDef>
|
||||||
|
<HediffDef>
|
||||||
|
<defName>ARA_Incubator_3_Reward_Hediffs</defName>
|
||||||
|
<label>行动激素</label>
|
||||||
|
<description>该阿拉克涅督虫腺体非常反常,会不断地分泌激素使得其处于亢奋状态,并且可以传导到与其链接的武装器官上。\n\n由于良好的孵化质量,阿拉克涅督虫获得了这个有利突变。</description>
|
||||||
|
<hediffClass>HediffWithComps</hediffClass>
|
||||||
|
<isBad>false</isBad>
|
||||||
|
<defaultLabelColor>(0.3, 0.7, 0.2)</defaultLabelColor>
|
||||||
|
<scenarioCanAdd>true</scenarioCanAdd>
|
||||||
|
<stages>
|
||||||
|
<li>
|
||||||
|
<statOffsets>
|
||||||
|
<MoveSpeed>0.25</MoveSpeed>
|
||||||
|
</statOffsets>
|
||||||
|
<statFactors>
|
||||||
|
<MeleeCooldownFactor>0.8</MeleeCooldownFactor>
|
||||||
|
</statFactors>
|
||||||
|
</li>
|
||||||
|
</stages>
|
||||||
|
</HediffDef>
|
||||||
|
<HediffDef>
|
||||||
|
<defName>ARA_Incubator_4_Reward_Hediffs</defName>
|
||||||
|
<label>高静态视力</label>
|
||||||
|
<description>该阿拉克涅督虫的有利突变使其获得了异于其他虫族的高级静态视力,填补了其视力的短板,使其射击时更加得心应手。\n\n由于良好的孵化质量,阿拉克涅督虫获得了这个有利突变。</description>
|
||||||
|
<hediffClass>HediffWithComps</hediffClass>
|
||||||
|
<isBad>false</isBad>
|
||||||
|
<defaultLabelColor>(0.3, 0.7, 0.2)</defaultLabelColor>
|
||||||
|
<scenarioCanAdd>true</scenarioCanAdd>
|
||||||
|
<stages>
|
||||||
|
<li>
|
||||||
|
<statFactors>
|
||||||
|
<RangedCooldownFactor>0.75</RangedCooldownFactor>
|
||||||
|
</statFactors>
|
||||||
|
</li>
|
||||||
|
</stages>
|
||||||
|
</HediffDef>
|
||||||
|
<HediffDef>
|
||||||
|
<defName>ARA_Incubator_5_Reward_Hediffs</defName>
|
||||||
|
<label>强壮肌肉</label>
|
||||||
|
<description>该阿拉克涅督虫壮的惊人——属于是营养过剩了。\n\n由于良好的孵化质量,阿拉克涅督虫获得了这个有利突变。</description>
|
||||||
|
<hediffClass>HediffWithComps</hediffClass>
|
||||||
|
<isBad>false</isBad>
|
||||||
|
<defaultLabelColor>(0.3, 0.7, 0.2)</defaultLabelColor>
|
||||||
|
<scenarioCanAdd>true</scenarioCanAdd>
|
||||||
|
<stages>
|
||||||
|
<li>
|
||||||
|
<statFactors>
|
||||||
|
<MeleeDamageFactor>2</MeleeDamageFactor>
|
||||||
|
</statFactors>
|
||||||
|
</li>
|
||||||
|
</stages>
|
||||||
|
</HediffDef>
|
||||||
|
<HediffDef>
|
||||||
|
<defName>ARA_Incubator_6_Reward_Hediffs</defName>
|
||||||
|
<label>中枢强化</label>
|
||||||
|
<description>该阿拉克涅督虫神经反应远超其他虫族,得益于更强大的反射,其行动变得敏捷而致命。\n\n由于良好的孵化质量,阿拉克涅督虫获得了这个有利突变。</description>
|
||||||
|
<hediffClass>HediffWithComps</hediffClass>
|
||||||
|
<isBad>false</isBad>
|
||||||
|
<defaultLabelColor>(0.3, 0.7, 0.2)</defaultLabelColor>
|
||||||
|
<scenarioCanAdd>true</scenarioCanAdd>
|
||||||
|
<stages>
|
||||||
|
<li>
|
||||||
|
<capMods>
|
||||||
|
<li>
|
||||||
|
<capacity>Consciousness</capacity>
|
||||||
|
<offset>0.15</offset>
|
||||||
|
</li>
|
||||||
|
</capMods>
|
||||||
|
</li>
|
||||||
|
</stages>
|
||||||
|
</HediffDef>
|
||||||
|
<HediffDef>
|
||||||
|
<defName>ARA_Incubator_7_Reward_Hediffs</defName>
|
||||||
|
<label>可塑记忆体</label>
|
||||||
|
<description>该阿拉克涅督虫的记忆体结构更加复杂,且能快速吸纳新的知识和经验。\n\n由于良好的孵化质量,阿拉克涅督虫获得了这个有利突变。</description>
|
||||||
|
<hediffClass>HediffWithComps</hediffClass>
|
||||||
|
<isBad>false</isBad>
|
||||||
|
<defaultLabelColor>(0.3, 0.7, 0.2)</defaultLabelColor>
|
||||||
|
<scenarioCanAdd>true</scenarioCanAdd>
|
||||||
|
<stages>
|
||||||
|
<li>
|
||||||
|
<statOffsets>
|
||||||
|
<GlobalLearningFactor>0.5</GlobalLearningFactor>
|
||||||
|
</statOffsets>
|
||||||
|
</li>
|
||||||
|
</stages>
|
||||||
|
</HediffDef>
|
||||||
|
<HediffDef>
|
||||||
|
<defName>ARA_Incubator_8_Reward_Hediffs</defName>
|
||||||
|
<label>凝血因子</label>
|
||||||
|
<description>该阿拉克涅督虫的凝血系统更加高效,多种其他督虫身上不具备的特殊凝血因子使得其流血速度大为减缓。\n\n由于良好的孵化质量,阿拉克涅督虫获得了这个有利突变。</description>
|
||||||
|
<hediffClass>HediffWithComps</hediffClass>
|
||||||
|
<isBad>false</isBad>
|
||||||
|
<defaultLabelColor>(0.3, 0.7, 0.2)</defaultLabelColor>
|
||||||
|
<scenarioCanAdd>true</scenarioCanAdd>
|
||||||
|
<stages>
|
||||||
|
<li>
|
||||||
|
<!-- 流血速度 -->
|
||||||
|
<totalBleedFactor>0.1</totalBleedFactor>
|
||||||
|
</li>
|
||||||
|
</stages>
|
||||||
|
</HediffDef>
|
||||||
|
</Defs>
|
||||||
@@ -699,7 +699,7 @@
|
|||||||
<AlienRace.ThingDef_AlienRace ParentName="ARA_NodeBase_Huge">
|
<AlienRace.ThingDef_AlienRace ParentName="ARA_NodeBase_Huge">
|
||||||
<defName>ArachnaeNode_Race_Myrmecocystus</defName>
|
<defName>ArachnaeNode_Race_Myrmecocystus</defName>
|
||||||
<label>阿拉克涅蜜罐种</label>
|
<label>阿拉克涅蜜罐种</label>
|
||||||
<description>阿拉克涅大型督虫之一,拥有广泛食谱的大型虫族,可以吞下许多未经处理的生物并将其分解为阿拉克涅虫蜜,以滋养虫群。\n\n她可以进行搬运、烹饪和种植工作,战斗技能非常差。</description>
|
<description>阿拉克涅大型督虫之一,拥有广泛食谱的大型虫族,可以吞下许多未经处理的生物并将其分解为阿拉克涅虫蜜,以滋养虫群。当虫群中的其他虫族感到饥饿时,她们会通过嘴对嘴的方式进行喂食,如果蜜罐满溢,她们还会将虫蜜排出以形成可供巢穴进行建筑的资源。\n\n她可以进行搬运、烹饪和种植工作,战斗技能非常差。</description>
|
||||||
<alienRace>
|
<alienRace>
|
||||||
<generalSettings>
|
<generalSettings>
|
||||||
<!-- 各种零件定义 -->
|
<!-- 各种零件定义 -->
|
||||||
@@ -775,6 +775,23 @@
|
|||||||
</race>
|
</race>
|
||||||
|
|
||||||
<comps>
|
<comps>
|
||||||
|
<li Class="ArachnaeSwarm.CompProperties_AutoMechCarrier">
|
||||||
|
<freeProduction>true</freeProduction>
|
||||||
|
<disableHediff>ARA_RaceBaseSwarmProduceSwitchHediff</disableHediff>
|
||||||
|
<fixedIngredient>ARA_InsectJelly</fixedIngredient>
|
||||||
|
<maxIngredientCount>1</maxIngredientCount>
|
||||||
|
<startingIngredientCount>1</startingIngredientCount>
|
||||||
|
<costPerPawn>1</costPerPawn>
|
||||||
|
<cooldownTicks>9999</cooldownTicks>
|
||||||
|
<productionQueue>
|
||||||
|
<li>
|
||||||
|
<pawnKind>ArachnaeBase_Race_Scavenger</pawnKind>
|
||||||
|
<count>2</count>
|
||||||
|
<cooldownTicks>5000</cooldownTicks>
|
||||||
|
</li>
|
||||||
|
</productionQueue>
|
||||||
|
<spawnEffecter>CocoonDestroyed</spawnEffecter>
|
||||||
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_NodeSwarmLifetime">
|
<li Class="ArachnaeSwarm.CompProperties_NodeSwarmLifetime">
|
||||||
<immuteHediff>ARA_Cycle_Suppression_Hediff</immuteHediff>
|
<immuteHediff>ARA_Cycle_Suppression_Hediff</immuteHediff>
|
||||||
<lifespanHediff>ARA_LifespanHediff</lifespanHediff>
|
<lifespanHediff>ARA_LifespanHediff</lifespanHediff>
|
||||||
@@ -785,6 +802,7 @@
|
|||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_HediffGiver">
|
<li Class="ArachnaeSwarm.CompProperties_HediffGiver">
|
||||||
<hediffs>
|
<hediffs>
|
||||||
|
<li>ARA_RaceBaseSwarmProduceSwitchHediff</li>
|
||||||
<li>ARA_Myrmecocystus_Production_InsectJelly</li>
|
<li>ARA_Myrmecocystus_Production_InsectJelly</li>
|
||||||
</hediffs>
|
</hediffs>
|
||||||
<addChance>1.0</addChance>
|
<addChance>1.0</addChance>
|
||||||
@@ -942,8 +960,8 @@
|
|||||||
<productionQueue>
|
<productionQueue>
|
||||||
<li>
|
<li>
|
||||||
<pawnKind>ArachnaeBase_Race_Scavenger</pawnKind>
|
<pawnKind>ArachnaeBase_Race_Scavenger</pawnKind>
|
||||||
<count>4</count>
|
<count>2</count>
|
||||||
<cooldownTicks>1000</cooldownTicks>
|
<cooldownTicks>5000</cooldownTicks>
|
||||||
</li>
|
</li>
|
||||||
</productionQueue>
|
</productionQueue>
|
||||||
<spawnEffecter>CocoonDestroyed</spawnEffecter>
|
<spawnEffecter>CocoonDestroyed</spawnEffecter>
|
||||||
@@ -1050,6 +1068,23 @@
|
|||||||
</race>
|
</race>
|
||||||
|
|
||||||
<comps>
|
<comps>
|
||||||
|
<li Class="ArachnaeSwarm.CompProperties_AutoMechCarrier">
|
||||||
|
<freeProduction>true</freeProduction>
|
||||||
|
<disableHediff>ARA_RaceBaseSwarmProduceSwitchHediff</disableHediff>
|
||||||
|
<fixedIngredient>ARA_InsectJelly</fixedIngredient>
|
||||||
|
<maxIngredientCount>1</maxIngredientCount>
|
||||||
|
<startingIngredientCount>1</startingIngredientCount>
|
||||||
|
<costPerPawn>1</costPerPawn>
|
||||||
|
<cooldownTicks>9999</cooldownTicks>
|
||||||
|
<productionQueue>
|
||||||
|
<li>
|
||||||
|
<pawnKind>ArachnaeBase_Race_Scavenger</pawnKind>
|
||||||
|
<count>2</count>
|
||||||
|
<cooldownTicks>5000</cooldownTicks>
|
||||||
|
</li>
|
||||||
|
</productionQueue>
|
||||||
|
<spawnEffecter>CocoonDestroyed</spawnEffecter>
|
||||||
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_HediffGiver">
|
<li Class="ArachnaeSwarm.CompProperties_HediffGiver">
|
||||||
<hediffs>
|
<hediffs>
|
||||||
<li>ARA_RaceBaseSwarmProduceSwitchHediff</li>
|
<li>ARA_RaceBaseSwarmProduceSwitchHediff</li>
|
||||||
|
|||||||
@@ -61,9 +61,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -94,9 +92,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -127,9 +123,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -160,9 +154,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -193,9 +185,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -325,9 +315,7 @@
|
|||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -376,9 +364,7 @@
|
|||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -427,9 +413,7 @@
|
|||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -479,9 +463,7 @@
|
|||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth_1Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_1Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -531,9 +513,7 @@
|
|||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth_1Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_1Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -583,9 +563,7 @@
|
|||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth_1Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_1Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -633,9 +611,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth_2Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_2Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ApparelInterceptor">
|
<li Class="ArachnaeSwarm.CompProperties_ApparelInterceptor">
|
||||||
@@ -713,9 +689,7 @@
|
|||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth_2Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_2Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
@@ -765,9 +739,7 @@
|
|||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Cloth_2Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Cloth_2Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
</comps>
|
</comps>
|
||||||
|
|||||||
@@ -332,9 +332,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
@@ -430,9 +428,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon_1Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_1Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
@@ -528,9 +524,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon_1Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_1Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
@@ -772,9 +766,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon_2Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_2Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
@@ -875,9 +867,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
@@ -991,9 +981,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon_1Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_1Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
@@ -1141,9 +1129,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon_2Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_2Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
@@ -1260,9 +1246,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon_2Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_2Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
@@ -1394,9 +1378,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon_2Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_2Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
@@ -1530,9 +1512,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon_1Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_1Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
@@ -1688,9 +1668,7 @@
|
|||||||
<comps>
|
<comps>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
<li Class="ArachnaeSwarm.CompProperties_ExtraIncubationInfo">
|
||||||
<cocoonDefs>
|
<cocoonDefs>
|
||||||
<li>ARA_Cocoon_Weapon_1Stage</li>
|
<li>ARA_Equipment_Ootheca</li>
|
||||||
<li>ARA_Cocoon_Weapon_1Stage_From_Death</li>
|
|
||||||
<li>ARA_BioforgeIncubator_Thing</li>
|
|
||||||
</cocoonDefs>
|
</cocoonDefs>
|
||||||
</li>
|
</li>
|
||||||
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
<li Class="ArachnaeSwarm.CompProperties_CustomUniqueWeapon" MayRequire="Ludeon.RimWorld.Odyssey">
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -3,7 +3,7 @@
|
|||||||
<TerrainDef>
|
<TerrainDef>
|
||||||
<defName>ARA_Incubator_Nutrient_Solution</defName>
|
<defName>ARA_Incubator_Nutrient_Solution</defName>
|
||||||
<label>阿拉克涅营养液</label>
|
<label>阿拉克涅营养液</label>
|
||||||
<description>阿拉克涅虫族孵化池的营养液。</description>
|
<description>阿拉克涅虫族孵化池的营养液,卵和茧都需要这种富含多种营养成分的液体以维系孵化进度。茧在孵化过程中会消耗营养液,必须有虫族定时重新填充营养液。</description>
|
||||||
<renderPrecedence>395</renderPrecedence>
|
<renderPrecedence>395</renderPrecedence>
|
||||||
<texturePath>Terrain/Surfaces/WaterShallowRamp</texturePath>
|
<texturePath>Terrain/Surfaces/WaterShallowRamp</texturePath>
|
||||||
<pollutedTexturePath>Terrain/Surfaces/WaterShallowRampPolluted</pollutedTexturePath>
|
<pollutedTexturePath>Terrain/Surfaces/WaterShallowRampPolluted</pollutedTexturePath>
|
||||||
@@ -55,6 +55,9 @@
|
|||||||
<cooldownTime>1.5</cooldownTime>
|
<cooldownTime>1.5</cooldownTime>
|
||||||
</li>
|
</li>
|
||||||
</tools>
|
</tools>
|
||||||
|
<costList>
|
||||||
|
<ARA_InsectJelly>1</ARA_InsectJelly>
|
||||||
|
</costList>
|
||||||
</TerrainDef>
|
</TerrainDef>
|
||||||
|
|
||||||
<ThingDef ParentName="BuildingNaturalBase">
|
<ThingDef ParentName="BuildingNaturalBase">
|
||||||
@@ -126,6 +129,14 @@
|
|||||||
<!-- <useRoomQualityFactor>true</useRoomQualityFactor> -->
|
<!-- <useRoomQualityFactor>true</useRoomQualityFactor> -->
|
||||||
<!-- 建筑血量影响质量 -->
|
<!-- 建筑血量影响质量 -->
|
||||||
<!-- <healthAffectsQuality>true</healthAffectsQuality> -->
|
<!-- <healthAffectsQuality>true</healthAffectsQuality> -->
|
||||||
|
|
||||||
|
<!-- 新增营养液不足伤害设置 -->
|
||||||
|
<nutrientDeficiencyDamageEnabled>true</nutrientDeficiencyDamageEnabled>
|
||||||
|
<nutrientDeficiencyDamageAmount>2</nutrientDeficiencyDamageAmount>
|
||||||
|
<nutrientDamageType>Burn</nutrientDamageType>
|
||||||
|
<stopIncubationWhenNutrientDeficient>true</stopIncubationWhenNutrientDeficient>
|
||||||
|
<!-- <showDamageMessages>true</showDamageMessages>
|
||||||
|
<damageMessageChance>0.1</damageMessageChance> -->
|
||||||
</li>
|
</li>
|
||||||
</modExtensions>
|
</modExtensions>
|
||||||
|
|
||||||
@@ -166,6 +177,45 @@
|
|||||||
<menuTitle>孵化菜单</menuTitle>
|
<menuTitle>孵化菜单</menuTitle>
|
||||||
<defaultIconPath>UI/Commands/IncubatorSwitch</defaultIconPath>
|
<defaultIconPath>UI/Commands/IncubatorSwitch</defaultIconPath>
|
||||||
|
|
||||||
|
<!-- 全局Hediff奖励(所有配置共享) -->
|
||||||
|
<globalExtraHediffs>
|
||||||
|
<li>ARA_Incubator_1_Reward_Hediffs</li>
|
||||||
|
<li>ARA_Incubator_2_Reward_Hediffs</li>
|
||||||
|
<li>ARA_Incubator_3_Reward_Hediffs</li>
|
||||||
|
<li>ARA_Incubator_4_Reward_Hediffs</li>
|
||||||
|
<li>ARA_Incubator_5_Reward_Hediffs</li>
|
||||||
|
<li>ARA_Incubator_6_Reward_Hediffs</li>
|
||||||
|
<li>ARA_Incubator_7_Reward_Hediffs</li>
|
||||||
|
<li>ARA_Incubator_8_Reward_Hediffs</li>
|
||||||
|
</globalExtraHediffs>
|
||||||
|
|
||||||
|
<globalHediffRewards>
|
||||||
|
<li Class="ArachnaeSwarm.QualityHediffReward">
|
||||||
|
<qualityThreshold>0.30</qualityThreshold>
|
||||||
|
<hediffCount>1</hediffCount>
|
||||||
|
<giveAllHediffs>false</giveAllHediffs>
|
||||||
|
<messageKey>ARA_QualityReward_1Hediff</messageKey>
|
||||||
|
</li>
|
||||||
|
<li Class="ArachnaeSwarm.QualityHediffReward">
|
||||||
|
<qualityThreshold>0.50</qualityThreshold>
|
||||||
|
<hediffCount>2</hediffCount>
|
||||||
|
<giveAllHediffs>false</giveAllHediffs>
|
||||||
|
<messageKey>ARA_QualityReward_2Hediff</messageKey>
|
||||||
|
</li>
|
||||||
|
<li Class="ArachnaeSwarm.QualityHediffReward">
|
||||||
|
<qualityThreshold>0.85</qualityThreshold>
|
||||||
|
<hediffCount>3</hediffCount>
|
||||||
|
<giveAllHediffs>false</giveAllHediffs>
|
||||||
|
<messageKey>ARA_QualityReward_3Hediff</messageKey>
|
||||||
|
</li>
|
||||||
|
<li Class="ArachnaeSwarm.QualityHediffReward">
|
||||||
|
<qualityThreshold>0.99</qualityThreshold>
|
||||||
|
<hediffCount>4</hediffCount>
|
||||||
|
<giveAllHediffs>false</giveAllHediffs>
|
||||||
|
<messageKey>ARA_QualityReward_4Hediff</messageKey>
|
||||||
|
</li>
|
||||||
|
</globalHediffRewards>
|
||||||
|
|
||||||
<incubationConfigs>
|
<incubationConfigs>
|
||||||
<li>
|
<li>
|
||||||
<pawnKind>ArachnaeNode_Race_ShieldHead</pawnKind>
|
<pawnKind>ArachnaeNode_Race_ShieldHead</pawnKind>
|
||||||
|
|||||||
@@ -144,29 +144,141 @@
|
|||||||
<ARA_OothecaIncubator.QualityVeryPoor>很差</ARA_OothecaIncubator.QualityVeryPoor>
|
<ARA_OothecaIncubator.QualityVeryPoor>很差</ARA_OothecaIncubator.QualityVeryPoor>
|
||||||
<ARA_OothecaIncubator.Quality>质量</ARA_OothecaIncubator.Quality>
|
<ARA_OothecaIncubator.Quality>质量</ARA_OothecaIncubator.Quality>
|
||||||
|
|
||||||
<ARA_OothecaIncubator.Incubating>正在孵化</ARA_OothecaIncubator.Incubating>
|
<!-- Hediff奖励相关 -->
|
||||||
<ARA_OothecaIncubator.Progress>进度</ARA_OothecaIncubator.Progress>
|
<HediffRewards>额外状态效果</HediffRewards>
|
||||||
<ARA_OothecaIncubator.TimeRemaining>剩余时间</ARA_OothecaIncubator.TimeRemaining>
|
<HediffRewardsTitle>孵化质量奖励 - 状态效果</HediffRewardsTitle>
|
||||||
<ARA_OothecaIncubator.Days>天</ARA_OothecaIncubator.Days>
|
<NoHediffRewards>没有可用的状态效果奖励。</NoHediffRewards>
|
||||||
<ARA_OothecaIncubator.Hours>小时</ARA_OothecaIncubator.Hours>
|
<QualityThresholds>质量阈值奖励</QualityThresholds>
|
||||||
<ARA_OothecaIncubator.Speed>速度</ARA_OothecaIncubator.Speed>
|
<AllHediffsReward>获得所有状态效果</AllHediffsReward>
|
||||||
<ARA_OothecaIncubator.Quality>质量</ARA_OothecaIncubator.Quality>
|
<HediffCountReward>获得{0}个随机状态效果</HediffCountReward>
|
||||||
<ARA_OothecaIncubator.LarvaOperating>幼虫正在操作</ARA_OothecaIncubator.LarvaOperating>
|
<AllHediffs>全部效果</AllHediffs>
|
||||||
<ARA_OothecaIncubator.SRemaining>秒剩余</ARA_OothecaIncubator.SRemaining>
|
<Hediffs>个效果</Hediffs>
|
||||||
<ARA_OothecaIncubator.LarvaOnWay>幼虫在途中</ARA_OothecaIncubator.LarvaOnWay>
|
<HediffRewardsAvailable>可用状态效果</HediffRewardsAvailable>
|
||||||
<ARA_OothecaIncubator.Target>目标</ARA_OothecaIncubator.Target>
|
<QualityForRewards>质量奖励:</QualityForRewards>
|
||||||
<ARA_OothecaIncubator.SpeedMultiplier>速度乘数</ARA_OothecaIncubator.SpeedMultiplier>
|
|
||||||
<ARA_OothecaIncubator.QualityMultiplier>质量乘数</ARA_OothecaIncubator.QualityMultiplier>
|
|
||||||
|
|
||||||
<ARA_OothecaIncubator.CallLarva>呼叫幼虫</ARA_OothecaIncubator.CallLarva>
|
<!-- 奖励消息 -->
|
||||||
<ARA_OothecaIncubator.CancelIncubation>取消孵化</ARA_OothecaIncubator.CancelIncubation>
|
<ARA_QualityReward_1Hediff>{0}因高质量的孵化获得了1个额外状态效果!</ARA_QualityReward_1Hediff>
|
||||||
<ARA_OothecaIncubator.CancelIncubationDesc>取消当前孵化过程,卵荚内容物将丢失</ARA_OothecaIncubator.CancelIncubationDesc>
|
<ARA_QualityReward_2Hediff>{0}因高质量的孵化获得了2个额外状态效果!</ARA_QualityReward_2Hediff>
|
||||||
|
<ARA_QualityReward_3Hediff>{0}因高质量的孵化获得了3个额外状态效果!</ARA_QualityReward_3Hediff>
|
||||||
|
<ARA_QualityReward_4Hediff>{0}因高质量的孵化获得了4个额外状态效果!</ARA_QualityReward_4Hediff>
|
||||||
|
<ARA_QualityReward_AllHediff>{0}因卓越的孵化质量获得了所有额外状态效果!</ARA_QualityReward_AllHediff>
|
||||||
|
<ARA_QualityReward_Default>{0}获得了{1}个额外状态效果!</ARA_QualityReward_Default>
|
||||||
|
|
||||||
<ARA_OothecaIncubator.IncubateLabel>孵化: {0}</ARA_OothecaIncubator.IncubateLabel>
|
<!-- 基础信息 -->
|
||||||
<ARA_OothecaIncubator.ButtonDesc>选择要孵化的生物类型。幼虫将前来激活卵荚。</ARA_OothecaIncubator.ButtonDesc>
|
<ARA_EquipmentIncubator.Incubating>正在孵化</ARA_EquipmentIncubator.Incubating>
|
||||||
<ARA_OothecaIncubator.ButtonLabel>当前选择: {0}</ARA_OothecaIncubator.ButtonLabel>
|
<ARA_EquipmentIncubator.Progress>进度</ARA_EquipmentIncubator.Progress>
|
||||||
<ARA_OothecaIncubator.IncubationTime>孵化时间: {0}天</ARA_OothecaIncubator.IncubationTime>
|
<ARA_EquipmentIncubator.TimeRemaining>剩余时间</ARA_EquipmentIncubator.TimeRemaining>
|
||||||
<ARA_OothecaIncubator.MenuTitle>选择孵化目标</ARA_OothecaIncubator.MenuTitle>
|
<ARA_EquipmentIncubator.Days>天</ARA_EquipmentIncubator.Days>
|
||||||
<ARA_OothecaIncubator.ResearchRequired>需要研究: </ARA_OothecaIncubator.ResearchRequired>
|
<ARA_EquipmentIncubator.Hours>小时</ARA_EquipmentIncubator.Hours>
|
||||||
<ARA_OothecaIncubator.TargetSwitched>孵化目标已切换为: {0}</ARA_OothecaIncubator.TargetSwitched>
|
<ARA_EquipmentIncubator.Speed>速度</ARA_EquipmentIncubator.Speed>
|
||||||
|
<ARA_EquipmentIncubator.Quality>品质</ARA_EquipmentIncubator.Quality>
|
||||||
|
<ARA_EquipmentIncubator.Target>目标</ARA_EquipmentIncubator.Target>
|
||||||
|
<ARA_EquipmentIncubator.SpeedMultiplier>速度倍率</ARA_EquipmentIncubator.SpeedMultiplier>
|
||||||
|
<ARA_EquipmentIncubator.QualityMultiplier>品质倍率</ARA_EquipmentIncubator.QualityMultiplier>
|
||||||
|
<!-- 速度因子描述 -->
|
||||||
|
<ARA_EquipmentIncubator.SpeedFactors>速度因子</ARA_EquipmentIncubator.SpeedFactors>
|
||||||
|
<ARA_EquipmentIncubator.InIncubatorRoom>✓ 在孵化室中</ARA_EquipmentIncubator.InIncubatorRoom>
|
||||||
|
<ARA_EquipmentIncubator.NotInIncubatorRoom>✗ 不在孵化室中</ARA_EquipmentIncubator.NotInIncubatorRoom>
|
||||||
|
<ARA_EquipmentIncubator.NutrientSolutions>营养液:{0}个(+{1}%)</ARA_EquipmentIncubator.NutrientSolutions>
|
||||||
|
<ARA_EquipmentIncubator.NoNutrientSolutionsNearby>附近没有营养液</ARA_EquipmentIncubator.NoNutrientSolutionsNearby>
|
||||||
|
<ARA_EquipmentIncubator.NutrientDetectionRadius>营养液检测半径:{0}格</ARA_EquipmentIncubator.NutrientDetectionRadius>
|
||||||
|
<ARA_EquipmentIncubator.TotalSpeedMultiplier>总速度倍率:{0}</ARA_EquipmentIncubator.TotalSpeedMultiplier>
|
||||||
|
<!-- 品质因子描述 -->
|
||||||
|
<ARA_EquipmentIncubator.QualityFactors>品质因子</ARA_EquipmentIncubator.QualityFactors>
|
||||||
|
<ARA_EquipmentIncubator.BuildingHealth>建筑血量:{0}</ARA_EquipmentIncubator.BuildingHealth>
|
||||||
|
<ARA_EquipmentIncubator.RoomFactorNormal>房间因子:正常</ARA_EquipmentIncubator.RoomFactorNormal>
|
||||||
|
<ARA_EquipmentIncubator.RoomFactorModified>房间因子:{0}</ARA_EquipmentIncubator.RoomFactorModified>
|
||||||
|
<ARA_EquipmentIncubator.NearbyOothecas>附近其他卵:{0}个(-{1}%)</ARA_EquipmentIncubator.NearbyOothecas>
|
||||||
|
<ARA_EquipmentIncubator.NoNearbyOothecas>附近没有其他卵</ARA_EquipmentIncubator.NoNearbyOothecas>
|
||||||
|
<ARA_EquipmentIncubator.OothecaDetectionRadius>其他卵检测半径:{0}格</ARA_EquipmentIncubator.OothecaDetectionRadius>
|
||||||
|
<ARA_EquipmentIncubator.TotalQualityMultiplier>总品质倍率:{0}</ARA_EquipmentIncubator.TotalQualityMultiplier>
|
||||||
|
<!-- 幼虫相关 -->
|
||||||
|
<ARA_EquipmentIncubator.CallLarvaTitle>呼叫幼虫</ARA_EquipmentIncubator.CallLarvaTitle>
|
||||||
|
<ARA_EquipmentIncubator.LarvaWillCome>幼虫将前来激活卵囊并孵化:</ARA_EquipmentIncubator.LarvaWillCome>
|
||||||
|
<ARA_EquipmentIncubator.LarvaSearchRadius>幼虫搜索半径:{0}格</ARA_EquipmentIncubator.LarvaSearchRadius>
|
||||||
|
<ARA_EquipmentIncubator.AlreadyIncubating>已经在孵化中</ARA_EquipmentIncubator.AlreadyIncubating>
|
||||||
|
<ARA_EquipmentIncubator.CancelFirst>请先取消当前孵化</ARA_EquipmentIncubator.CancelFirst>
|
||||||
|
<ARA_EquipmentIncubator.LarvaAlreadyOnWay>幼虫已在路上</ARA_EquipmentIncubator.LarvaAlreadyOnWay>
|
||||||
|
<ARA_EquipmentIncubator.NoTargetSelected>未选择孵化目标</ARA_EquipmentIncubator.NoTargetSelected>
|
||||||
|
<ARA_EquipmentIncubator.ResearchRequiredFor>需要研究:{1}才能孵化{0}</ARA_EquipmentIncubator.ResearchRequiredFor>
|
||||||
|
<ARA_EquipmentIncubator.ResearchNotCompleted>研究未完成</ARA_EquipmentIncubator.ResearchNotCompleted>
|
||||||
|
<ARA_EquipmentIncubator.NoLarvaeFound>未找到幼虫</ARA_EquipmentIncubator.NoLarvaeFound>
|
||||||
|
<ARA_EquipmentIncubator.LarvaMustBeRace>幼虫必须是ArachnaeBase_Race_Larva种族</ARA_EquipmentIncubator.LarvaMustBeRace>
|
||||||
|
<ARA_EquipmentIncubator.LarvaCalled>已呼叫幼虫</ARA_EquipmentIncubator.LarvaCalled>
|
||||||
|
<ARA_EquipmentIncubator.ArriveShortly>将很快到达</ARA_EquipmentIncubator.ArriveShortly>
|
||||||
|
<ARA_EquipmentIncubator.LarvaArrived>幼虫已到达</ARA_EquipmentIncubator.LarvaArrived>
|
||||||
|
<ARA_EquipmentIncubator.ActivatingOotheca>正在激活卵囊</ARA_EquipmentIncubator.ActivatingOotheca>
|
||||||
|
<ARA_EquipmentIncubator.IncubationStarted>孵化开始:</ARA_EquipmentIncubator.IncubationStarted>
|
||||||
|
<ARA_EquipmentIncubator.ProcessWillComplete>过程将在</ARA_EquipmentIncubator.ProcessWillComplete>
|
||||||
|
<ARA_EquipmentIncubator.DaysBaseTime>天内完成(基础时间)</ARA_EquipmentIncubator.DaysBaseTime>
|
||||||
|
<ARA_EquipmentIncubator.LarvaOperating>幼虫操作中</ARA_EquipmentIncubator.LarvaOperating>
|
||||||
|
<ARA_EquipmentIncubator.SRemaining>秒剩余</ARA_EquipmentIncubator.SRemaining>
|
||||||
|
<ARA_EquipmentIncubator.LarvaOnWay>幼虫在路上</ARA_EquipmentIncubator.LarvaOnWay>
|
||||||
|
<!-- 孵化状态 -->
|
||||||
|
<ARA_EquipmentIncubator.IncubationCancelled>孵化已取消</ARA_EquipmentIncubator.IncubationCancelled>
|
||||||
|
<ARA_EquipmentIncubator.ContentsLost>内容物已丢失</ARA_EquipmentIncubator.ContentsLost>
|
||||||
|
<ARA_EquipmentIncubator.IncubationComplete>孵化完成:</ARA_EquipmentIncubator.IncubationComplete>
|
||||||
|
<ARA_EquipmentIncubator.HasEmergedWith>已生成,品质:</ARA_EquipmentIncubator.HasEmergedWith>
|
||||||
|
<ARA_EquipmentIncubator.QualityExcellent>极佳</ARA_EquipmentIncubator.QualityExcellent>
|
||||||
|
<ARA_EquipmentIncubator.QualityGood>良好</ARA_EquipmentIncubator.QualityGood>
|
||||||
|
<ARA_EquipmentIncubator.QualityAverage>普通</ARA_EquipmentIncubator.QualityAverage>
|
||||||
|
<ARA_EquipmentIncubator.QualityPoor>差</ARA_EquipmentIncubator.QualityPoor>
|
||||||
|
<ARA_EquipmentIncubator.QualityVeryPoor>极差</ARA_EquipmentIncubator.QualityVeryPoor>
|
||||||
|
<!-- 按钮和菜单 -->
|
||||||
|
<ARA_EquipmentIncubator.CallLarva>呼叫幼虫</ARA_EquipmentIncubator.CallLarva>
|
||||||
|
<ARA_EquipmentIncubator.CancelIncubation>取消孵化</ARA_EquipmentIncubator.CancelIncubation>
|
||||||
|
<ARA_EquipmentIncubator.CancelIncubationDesc>取消当前孵化,已消耗的资源将丢失</ARA_EquipmentIncubator.CancelIncubationDesc>
|
||||||
|
<ARA_EquipmentIncubator.IncubateLabel>孵化:{0}</ARA_EquipmentIncubator.IncubateLabel>
|
||||||
|
<ARA_EquipmentIncubator.ButtonLabel>孵化:{0}</ARA_EquipmentIncubator.ButtonLabel>
|
||||||
|
<ARA_EquipmentIncubator.IncubationTime>孵化时间:{0}天</ARA_EquipmentIncubator.IncubationTime>
|
||||||
|
<ARA_EquipmentIncubator.ResearchCompleted>研究已完成:{0}</ARA_EquipmentIncubator.ResearchCompleted>
|
||||||
|
<ARA_EquipmentIncubator.ResearchRequired>需要研究:{0}</ARA_EquipmentIncubator.ResearchRequired>
|
||||||
|
<ARA_EquipmentIncubator.NoResearchRequired>无需研究</ARA_EquipmentIncubator.NoResearchRequired>
|
||||||
|
<ARA_EquipmentIncubator.ButtonDesc>点击选择要孵化的物品</ARA_EquipmentIncubator.ButtonDesc>
|
||||||
|
<ARA_EquipmentIncubator.MenuTitle>选择孵化目标</ARA_EquipmentIncubator.MenuTitle>
|
||||||
|
<ARA_EquipmentIncubator.TargetSwitched>已切换目标:{0}</ARA_EquipmentIncubator.TargetSwitched>
|
||||||
|
<!-- 营养液消耗相关 -->
|
||||||
|
<ARA_EquipmentIncubator.StartedNutrientConsumption>开始消耗营养液...</ARA_EquipmentIncubator.StartedNutrientConsumption>
|
||||||
|
<ARA_EquipmentIncubator.NutrientRequirementsMet>营养液需求已满足!</ARA_EquipmentIncubator.NutrientRequirementsMet>
|
||||||
|
<ARA_EquipmentIncubator.NutrientConsumption>营养液消耗</ARA_EquipmentIncubator.NutrientConsumption>
|
||||||
|
<ARA_EquipmentIncubator.NoNutrientCost>无需营养液</ARA_EquipmentIncubator.NoNutrientCost>
|
||||||
|
<ARA_EquipmentIncubator.NutrientRequirement>所需营养液地块:{0}</ARA_EquipmentIncubator.NutrientRequirement>
|
||||||
|
<ARA_EquipmentIncubator.NutrientConsumed>已消耗:{0}</ARA_EquipmentIncubator.NutrientConsumed>
|
||||||
|
<ARA_EquipmentIncubator.NutrientProgress>进度:{0}</ARA_EquipmentIncubator.NutrientProgress>
|
||||||
|
<ARA_EquipmentIncubator.ConsumingNutrients>正在消耗营养液...</ARA_EquipmentIncubator.ConsumingNutrients>
|
||||||
|
<ARA_EquipmentIncubator.NutrientDeficiencyDamage>茧因缺乏营养液受到{0}点伤害!</ARA_EquipmentIncubator.NutrientDeficiencyDamage>
|
||||||
|
<ARA_EquipmentIncubator.IncubationPausedNoNutrients>{0}的孵化因缺乏营养液而暂停</ARA_EquipmentIncubator.IncubationPausedNoNutrients>
|
||||||
|
<ARA_EquipmentIncubator.IncubationPausedWarning>警告:孵化暂停 - 无可用营养液!</ARA_EquipmentIncubator.IncubationPausedWarning>
|
||||||
|
<ARA_EquipmentIncubator.NutrientDeficiencyWarning>警告:无可用营养液 - 正在受到伤害!</ARA_EquipmentIncubator.NutrientDeficiencyWarning>
|
||||||
|
<ARA_EquipmentIncubator.LowHealthWarning>建筑血量极低:{0}</ARA_EquipmentIncubator.LowHealthWarning>
|
||||||
|
<ARA_EquipmentIncubator.EstimatedNutrientCost>预计所需营养液:{0}</ARA_EquipmentIncubator.EstimatedNutrientCost>
|
||||||
|
<!-- 其他 -->
|
||||||
|
<ARA_EquipmentIncubator.NutrientSearchRadius>营养液吸收半径:{0}格</ARA_EquipmentIncubator.NutrientSearchRadius>
|
||||||
|
<ARA_EquipmentIncubator.SearchRadius>搜索半径:{0}格</ARA_EquipmentIncubator.SearchRadius>
|
||||||
|
<ARA_EquipmentIncubator.AvailableCells>可用营养液地块:{0}</ARA_EquipmentIncubator.AvailableCells>
|
||||||
|
<ARA_EquipmentIncubator.NoAvailableCells>范围内无可用营养液地块!</ARA_EquipmentIncubator.NoAvailableCells>
|
||||||
|
|
||||||
|
<ARA_EquipmentIncubator.IncubationTab>孵化进度</ARA_EquipmentIncubator.IncubationTab>
|
||||||
|
|
||||||
|
<!-- 错误消息 -->
|
||||||
|
<ARA_EquipmentIncubator.NotAnEquipmentOotheca>这不是一个装备茧</ARA_EquipmentIncubator.NotAnEquipmentOotheca>
|
||||||
|
|
||||||
|
<!-- 标签和标题 -->
|
||||||
|
<ARA_EquipmentIncubator.IncubationProgress>孵化进度</ARA_EquipmentIncubator.IncubationProgress>
|
||||||
|
<ARA_EquipmentIncubator.IncubationProgressLabel>孵化进度</ARA_EquipmentIncubator.IncubationProgressLabel>
|
||||||
|
<ARA_EquipmentIncubator.QualityProgress>品质进度</ARA_EquipmentIncubator.QualityProgress>
|
||||||
|
|
||||||
|
<!-- 幼虫状态 -->
|
||||||
|
<ARA_EquipmentIncubator.LarvaIsActivatingOotheca>幼虫正在激活茧</ARA_EquipmentIncubator.LarvaIsActivatingOotheca>
|
||||||
|
<ARA_EquipmentIncubator.SecondsRemaining>秒剩余</ARA_EquipmentIncubator.SecondsRemaining>
|
||||||
|
<ARA_EquipmentIncubator.LarvaIsOnTheWay>幼虫正在路上</ARA_EquipmentIncubator.LarvaIsOnTheWay>
|
||||||
|
|
||||||
|
<!-- 准备状态 -->
|
||||||
|
<ARA_EquipmentIncubator.ReadyToIncubate>准备孵化</ARA_EquipmentIncubator.ReadyToIncubate>
|
||||||
|
<ARA_EquipmentIncubator.Requires>需要</ARA_EquipmentIncubator.Requires>
|
||||||
|
<ARA_EquipmentIncubator.NoIncubationTargetSelected>未选择孵化目标</ARA_EquipmentIncubator.NoIncubationTargetSelected>
|
||||||
|
|
||||||
|
<!-- 营养液状态 -->
|
||||||
|
<ARA_EquipmentIncubator.WaitingForNutrients>等待营养液...</ARA_EquipmentIncubator.WaitingForNutrients>
|
||||||
|
<ARA_Consumed>已消耗</ARA_Consumed>
|
||||||
</LanguageData>
|
</LanguageData>
|
||||||
|
|||||||
Binary file not shown.
@@ -1,21 +1,33 @@
|
|||||||
{
|
{
|
||||||
"Version": 1,
|
"Version": 1,
|
||||||
"WorkspaceRootPath": "E:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\",
|
"WorkspaceRootPath": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\",
|
||||||
"Documents": [
|
"Documents": [
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|e:\\steamlibrary\\steamapps\\common\\rimworld\\mods\\arachnaeswarm\\source\\arachnaeswarm\\buildings\\building_equipmentootheca\\building_equipmentootheca.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|d:\\steamlibrary\\steamapps\\common\\rimworld\\mods\\arachnaeswarm\\source\\arachnaeswarm\\buildings\\building_ootheca\\compproperties_incubatordata.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:buildings\\building_equipmentootheca\\building_equipmentootheca.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:buildings\\building_ootheca\\compproperties_incubatordata.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|e:\\steamlibrary\\steamapps\\common\\rimworld\\mods\\arachnaeswarm\\source\\arachnaeswarm\\buildings\\building_ootheca\\building_ootheca.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\buildings\\building_ootheca\\building_ootheca.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:buildings\\building_ootheca\\building_ootheca.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:buildings\\building_ootheca\\building_ootheca.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|e:\\steamlibrary\\steamapps\\common\\rimworld\\mods\\arachnaeswarm\\source\\arachnaeswarm\\buildings\\building_equipmentootheca\\compproperties_equipmentincubatordata.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|d:\\steamlibrary\\steamapps\\common\\rimworld\\mods\\arachnaeswarm\\source\\arachnaeswarm\\buildings\\building_ootheca\\oothecaincubatorextension.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
|
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:buildings\\building_ootheca\\oothecaincubatorextension.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|d:\\steamlibrary\\steamapps\\common\\rimworld\\mods\\arachnaeswarm\\source\\arachnaeswarm\\buildings\\building_equipmentootheca\\itab_equipmentootheca_incubation.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
|
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:buildings\\building_equipmentootheca\\itab_equipmentootheca_incubation.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|d:\\steamlibrary\\steamapps\\common\\rimworld\\mods\\arachnaeswarm\\source\\arachnaeswarm\\buildings\\building_equipmentootheca\\building_equipmentootheca.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
|
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:buildings\\building_equipmentootheca\\building_equipmentootheca.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\buildings\\building_equipmentootheca\\compproperties_equipmentincubatordata.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:buildings\\building_equipmentootheca\\compproperties_equipmentincubatordata.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:buildings\\building_equipmentootheca\\compproperties_equipmentincubatordata.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|e:\\steamlibrary\\steamapps\\common\\rimworld\\mods\\arachnaeswarm\\source\\arachnaeswarm\\ara_hediffdefof.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
"AbsoluteMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\ara_hediffdefof.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
|
||||||
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:ara_hediffdefof.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
"RelativeMoniker": "D:0:0:{EAE0DB6B-E282-C812-7F5A-6D13E9D24581}|ArachnaeSwarm.csproj|solutionrelative:ara_hediffdefof.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
@@ -26,21 +38,60 @@
|
|||||||
"DocumentGroups": [
|
"DocumentGroups": [
|
||||||
{
|
{
|
||||||
"DockedWidth": 200,
|
"DockedWidth": 200,
|
||||||
"SelectedChildIndex": 1,
|
"SelectedChildIndex": 0,
|
||||||
"Children": [
|
"Children": [
|
||||||
|
{
|
||||||
|
"$type": "Document",
|
||||||
|
"DocumentIndex": 0,
|
||||||
|
"Title": "CompProperties_IncubatorData.cs",
|
||||||
|
"DocumentMoniker": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_Ootheca\\CompProperties_IncubatorData.cs",
|
||||||
|
"RelativeDocumentMoniker": "Buildings\\Building_Ootheca\\CompProperties_IncubatorData.cs",
|
||||||
|
"ToolTip": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_Ootheca\\CompProperties_IncubatorData.cs*",
|
||||||
|
"RelativeToolTip": "Buildings\\Building_Ootheca\\CompProperties_IncubatorData.cs*",
|
||||||
|
"ViewState": "AgIAAAIBAAAAAAAAAAAawC8BAABeAAAAAAAAAA==",
|
||||||
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
||||||
|
"WhenOpened": "2025-12-16T02:36:56.126Z",
|
||||||
|
"EditorCaption": ""
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"$type": "Bookmark",
|
"$type": "Bookmark",
|
||||||
"Name": "ST:0:0:{1c4feeaa-4718-4aa9-859d-94ce25d182ba}"
|
"Name": "ST:0:0:{1c4feeaa-4718-4aa9-859d-94ce25d182ba}"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 0,
|
"DocumentIndex": 2,
|
||||||
|
"Title": "OothecaIncubatorExtension.cs",
|
||||||
|
"DocumentMoniker": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_Ootheca\\OothecaIncubatorExtension.cs",
|
||||||
|
"RelativeDocumentMoniker": "Buildings\\Building_Ootheca\\OothecaIncubatorExtension.cs",
|
||||||
|
"ToolTip": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_Ootheca\\OothecaIncubatorExtension.cs",
|
||||||
|
"RelativeToolTip": "Buildings\\Building_Ootheca\\OothecaIncubatorExtension.cs",
|
||||||
|
"ViewState": "AgIAAAAAAAAAAAAAAAAAAAkAAAArAAAAAAAAAA==",
|
||||||
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
||||||
|
"WhenOpened": "2025-12-16T00:38:04.247Z",
|
||||||
|
"EditorCaption": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$type": "Document",
|
||||||
|
"DocumentIndex": 3,
|
||||||
|
"Title": "ITab_EquipmentOotheca_Incubation.cs",
|
||||||
|
"DocumentMoniker": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_EquipmentOotheca\\ITab_EquipmentOotheca_Incubation.cs",
|
||||||
|
"RelativeDocumentMoniker": "Buildings\\Building_EquipmentOotheca\\ITab_EquipmentOotheca_Incubation.cs",
|
||||||
|
"ToolTip": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_EquipmentOotheca\\ITab_EquipmentOotheca_Incubation.cs",
|
||||||
|
"RelativeToolTip": "Buildings\\Building_EquipmentOotheca\\ITab_EquipmentOotheca_Incubation.cs",
|
||||||
|
"ViewState": "AgIAAIAAAAAAAAAAAADgv5AAAAAAAAAAAAAAAA==",
|
||||||
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
||||||
|
"WhenOpened": "2025-12-16T00:29:36.407Z",
|
||||||
|
"EditorCaption": ""
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"$type": "Document",
|
||||||
|
"DocumentIndex": 4,
|
||||||
"Title": "Building_EquipmentOotheca.cs",
|
"Title": "Building_EquipmentOotheca.cs",
|
||||||
"DocumentMoniker": "E:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_EquipmentOotheca\\Building_EquipmentOotheca.cs",
|
"DocumentMoniker": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_EquipmentOotheca\\Building_EquipmentOotheca.cs",
|
||||||
"RelativeDocumentMoniker": "Buildings\\Building_EquipmentOotheca\\Building_EquipmentOotheca.cs",
|
"RelativeDocumentMoniker": "Buildings\\Building_EquipmentOotheca\\Building_EquipmentOotheca.cs",
|
||||||
"ToolTip": "E:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_EquipmentOotheca\\Building_EquipmentOotheca.cs*",
|
"ToolTip": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_EquipmentOotheca\\Building_EquipmentOotheca.cs",
|
||||||
"RelativeToolTip": "Buildings\\Building_EquipmentOotheca\\Building_EquipmentOotheca.cs*",
|
"RelativeToolTip": "Buildings\\Building_EquipmentOotheca\\Building_EquipmentOotheca.cs",
|
||||||
"ViewState": "AgIAANoBAAAAAAAAAAAAAAACAABSAAAAAAAAAA==",
|
"ViewState": "AgIAAEgCAAAAAAAAAAAewF8CAABDAAAAAAAAAA==",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
||||||
"WhenOpened": "2025-12-15T18:22:14.171Z",
|
"WhenOpened": "2025-12-15T18:22:14.171Z",
|
||||||
"EditorCaption": ""
|
"EditorCaption": ""
|
||||||
@@ -49,22 +100,22 @@
|
|||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 1,
|
"DocumentIndex": 1,
|
||||||
"Title": "Building_Ootheca.cs",
|
"Title": "Building_Ootheca.cs",
|
||||||
"DocumentMoniker": "E:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_Ootheca\\Building_Ootheca.cs",
|
"DocumentMoniker": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_Ootheca\\Building_Ootheca.cs",
|
||||||
"RelativeDocumentMoniker": "Buildings\\Building_Ootheca\\Building_Ootheca.cs",
|
"RelativeDocumentMoniker": "Buildings\\Building_Ootheca\\Building_Ootheca.cs",
|
||||||
"ToolTip": "E:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_Ootheca\\Building_Ootheca.cs",
|
"ToolTip": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_Ootheca\\Building_Ootheca.cs",
|
||||||
"RelativeToolTip": "Buildings\\Building_Ootheca\\Building_Ootheca.cs",
|
"RelativeToolTip": "Buildings\\Building_Ootheca\\Building_Ootheca.cs",
|
||||||
"ViewState": "AgIAAAAAAAAAAAAAAADwvwAAAAAAAAAAAAAAAA==",
|
"ViewState": "AgIAACkBAAAAAAAAAAAhwC0BAAApAAAAAAAAAA==",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
||||||
"WhenOpened": "2025-12-15T18:22:12.217Z",
|
"WhenOpened": "2025-12-15T18:22:12.217Z",
|
||||||
"EditorCaption": ""
|
"EditorCaption": ""
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 2,
|
"DocumentIndex": 5,
|
||||||
"Title": "CompProperties_EquipmentIncubatorData.cs",
|
"Title": "CompProperties_EquipmentIncubatorData.cs",
|
||||||
"DocumentMoniker": "E:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_EquipmentOotheca\\CompProperties_EquipmentIncubatorData.cs",
|
"DocumentMoniker": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_EquipmentOotheca\\CompProperties_EquipmentIncubatorData.cs",
|
||||||
"RelativeDocumentMoniker": "Buildings\\Building_EquipmentOotheca\\CompProperties_EquipmentIncubatorData.cs",
|
"RelativeDocumentMoniker": "Buildings\\Building_EquipmentOotheca\\CompProperties_EquipmentIncubatorData.cs",
|
||||||
"ToolTip": "E:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_EquipmentOotheca\\CompProperties_EquipmentIncubatorData.cs",
|
"ToolTip": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\Buildings\\Building_EquipmentOotheca\\CompProperties_EquipmentIncubatorData.cs",
|
||||||
"RelativeToolTip": "Buildings\\Building_EquipmentOotheca\\CompProperties_EquipmentIncubatorData.cs",
|
"RelativeToolTip": "Buildings\\Building_EquipmentOotheca\\CompProperties_EquipmentIncubatorData.cs",
|
||||||
"ViewState": "AgIAAAAAAAAAAAAAAAAAACYAAAAaAAAAAAAAAA==",
|
"ViewState": "AgIAAAAAAAAAAAAAAAAAACYAAAAaAAAAAAAAAA==",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
||||||
@@ -73,16 +124,15 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"$type": "Document",
|
"$type": "Document",
|
||||||
"DocumentIndex": 3,
|
"DocumentIndex": 6,
|
||||||
"Title": "ARA_HediffDefOf.cs",
|
"Title": "ARA_HediffDefOf.cs",
|
||||||
"DocumentMoniker": "E:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\ARA_HediffDefOf.cs",
|
"DocumentMoniker": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\ARA_HediffDefOf.cs",
|
||||||
"RelativeDocumentMoniker": "ARA_HediffDefOf.cs",
|
"RelativeDocumentMoniker": "ARA_HediffDefOf.cs",
|
||||||
"ToolTip": "E:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\ARA_HediffDefOf.cs",
|
"ToolTip": "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\ArachnaeSwarm\\Source\\ArachnaeSwarm\\ARA_HediffDefOf.cs",
|
||||||
"RelativeToolTip": "ARA_HediffDefOf.cs",
|
"RelativeToolTip": "ARA_HediffDefOf.cs",
|
||||||
"ViewState": "AgIAAAAAAAAAAAAAAADwvxgAAAAdAAAAAAAAAA==",
|
"ViewState": "AgIAAAAAAAAAAAAAAADwvxgAAAAdAAAAAAAAAA==",
|
||||||
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
|
||||||
"WhenOpened": "2025-12-15T17:32:18.493Z",
|
"WhenOpened": "2025-12-15T17:32:18.493Z"
|
||||||
"EditorCaption": ""
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -33,12 +33,303 @@ namespace ArachnaeSwarm
|
|||||||
private float qualityMultiplier = 1.0f;
|
private float qualityMultiplier = 1.0f;
|
||||||
private float qualityProgress = 0f;
|
private float qualityProgress = 0f;
|
||||||
private float qualityTotal = 0f;
|
private float qualityTotal = 0f;
|
||||||
|
// === 新增:营养液消耗相关字段 ===
|
||||||
|
private int totalNutrientCost = 0; // 总共需要的营养液地块数量
|
||||||
|
private int consumedNutrientCount = 0; // 已消耗的营养液地块数量
|
||||||
|
private int lastConsumeCheckTick = -1; // 上次检查消耗的时间
|
||||||
|
private const int ConsumeCheckInterval = 250; // 检查间隔(tick)
|
||||||
|
private const int ConsumeRadius = 5; // 搜索半径
|
||||||
|
private List<IntVec3> consumedCells = new List<IntVec3>(); // 已消耗的单元格记录
|
||||||
|
private bool hasStartedConsumption = false; // 是否已开始消耗
|
||||||
|
private float consumeProgress = 0f; // 消耗进度(0-1)
|
||||||
|
|
||||||
|
// === 新增属性 ===
|
||||||
|
public int TotalNutrientCost => totalNutrientCost;
|
||||||
|
public int ConsumedNutrientCount => consumedNutrientCount;
|
||||||
|
public float NutrientProgress => totalNutrientCost > 0 ? (float)consumedNutrientCount / totalNutrientCost : 0f;
|
||||||
|
public bool HasEnoughNutrients => consumedNutrientCount >= totalNutrientCost;
|
||||||
|
public bool IsConsuming => hasStartedConsumption && !HasEnoughNutrients && isIncubating;
|
||||||
|
|
||||||
|
|
||||||
|
// === 新增:营养液消耗方法 ===
|
||||||
|
|
||||||
|
// 初始化营养液消耗需求
|
||||||
|
private void InitializeNutrientConsumption()
|
||||||
|
{
|
||||||
|
if (incubatingThingDef == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
// 获取孵化成本统计值
|
||||||
|
var costStat = DefDatabase<StatDef>.GetNamedSilentFail("ARA_IncubationCost");
|
||||||
|
if (costStat != null)
|
||||||
|
{
|
||||||
|
totalNutrientCost = Mathf.RoundToInt(incubatingThingDef.GetStatValueAbstract(costStat, null));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
totalNutrientCost = 0; // 如果统计不存在,则不需要消耗
|
||||||
|
}
|
||||||
|
|
||||||
|
consumedNutrientCount = 0;
|
||||||
|
consumedCells.Clear();
|
||||||
|
hasStartedConsumption = false;
|
||||||
|
consumeProgress = 0f;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 检查并消耗营养液
|
||||||
|
private void CheckAndConsumeNutrients()
|
||||||
|
{
|
||||||
|
if (!isIncubating || incubatingThingDef == null || HasEnoughNutrients)
|
||||||
|
return;
|
||||||
|
// 第一次检查时标记开始消耗
|
||||||
|
if (!hasStartedConsumption)
|
||||||
|
{
|
||||||
|
hasStartedConsumption = true;
|
||||||
|
Messages.Message("ARA_EquipmentIncubator.StartedNutrientConsumption".Translate(),
|
||||||
|
this, MessageTypeDefOf.SilentInput);
|
||||||
|
}
|
||||||
|
// 计算本次应该消耗的数量
|
||||||
|
// 基于孵化进度来动态计算
|
||||||
|
float targetProgress = AdjustedProgressPercent;
|
||||||
|
int targetConsumed = Mathf.RoundToInt(targetProgress * totalNutrientCost);
|
||||||
|
int toConsume = targetConsumed - consumedNutrientCount;
|
||||||
|
if (toConsume <= 0)
|
||||||
|
return;
|
||||||
|
// 查找可消耗的营养液单元格
|
||||||
|
List<IntVec3> availableCells = FindNutrientCells();
|
||||||
|
int consumedThisTick = 0;
|
||||||
|
for (int i = 0; i < Mathf.Min(toConsume, availableCells.Count); i++)
|
||||||
|
{
|
||||||
|
if (ConsumeNutrientCell(availableCells[i]))
|
||||||
|
{
|
||||||
|
consumedThisTick++;
|
||||||
|
consumedNutrientCount++;
|
||||||
|
// 添加到已消耗列表
|
||||||
|
consumedCells.Add(availableCells[i]);
|
||||||
|
if (HasEnoughNutrients)
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (consumedThisTick > 0)
|
||||||
|
{
|
||||||
|
consumeProgress = NutrientProgress;
|
||||||
|
// 如果达到需求,显示消息
|
||||||
|
if (HasEnoughNutrients)
|
||||||
|
{
|
||||||
|
Messages.Message("ARA_EquipmentIncubator.NutrientRequirementsMet".Translate(),
|
||||||
|
this, MessageTypeDefOf.PositiveEvent);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (Ext.nutrientDeficiencyDamageEnabled && toConsume > 0)
|
||||||
|
{
|
||||||
|
// === 新增:没有找到营养液,造成伤害 ===
|
||||||
|
ApplyNutrientDeficiencyDamage();
|
||||||
|
|
||||||
|
// === 新增:如果设置停止孵化,则暂停进度 ===
|
||||||
|
if (Ext.stopIncubationWhenNutrientDeficient)
|
||||||
|
{
|
||||||
|
// 暂停孵化进度,直到找到营养液
|
||||||
|
// 我们通过不增加incubationProgress来实现
|
||||||
|
// 但这里需要特殊处理,我们在Tick方法中处理
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// === 新增:应用营养液不足的伤害 ===
|
||||||
|
private void ApplyNutrientDeficiencyDamage()
|
||||||
|
{
|
||||||
|
if (Ext.nutrientDeficiencyDamageAmount <= 0f || Ext.nutrientDamageType == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
// 计算实际伤害量
|
||||||
|
float damageAmount = Ext.nutrientDeficiencyDamageAmount;
|
||||||
|
|
||||||
|
// 如果建筑血量已经很低,减少伤害以避免立即摧毁
|
||||||
|
float healthPercent = (float)HitPoints / MaxHitPoints;
|
||||||
|
if (healthPercent < 0.3f)
|
||||||
|
{
|
||||||
|
damageAmount *= 0.5f; // 血量低于30%时,伤害减半
|
||||||
|
}
|
||||||
|
|
||||||
|
if (healthPercent < 0.1f)
|
||||||
|
{
|
||||||
|
damageAmount *= 0.2f; // 血量低于10%时,伤害减为20%
|
||||||
|
}
|
||||||
|
|
||||||
|
// 应用伤害
|
||||||
|
DamageInfo damageInfo = new DamageInfo(
|
||||||
|
Ext.nutrientDamageType,
|
||||||
|
damageAmount,
|
||||||
|
armorPenetration: 0,
|
||||||
|
angle: -1f,
|
||||||
|
instigator: null,
|
||||||
|
hitPart: null,
|
||||||
|
weapon: null,
|
||||||
|
category: DamageInfo.SourceCategory.ThingOrUnknown,
|
||||||
|
intendedTarget: this
|
||||||
|
);
|
||||||
|
|
||||||
|
TakeDamage(damageInfo);
|
||||||
|
|
||||||
|
// 显示伤害消息(几率性)
|
||||||
|
if (Ext.showDamageMessages && Rand.Chance(Ext.damageMessageChance))
|
||||||
|
{
|
||||||
|
Messages.Message("ARA_EquipmentIncubator.NutrientDeficiencyDamage".Translate(damageAmount.ToString("F1")),
|
||||||
|
this, MessageTypeDefOf.NegativeEvent);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 更新质量乘数(因为血量变化会影响质量)
|
||||||
|
UpdateQualityMultiplier();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
Log.Error($"Failed to apply nutrient deficiency damage: {ex.Message}");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 查找可消耗的营养液单元格
|
||||||
|
public List<IntVec3> FindNutrientCells()
|
||||||
|
{
|
||||||
|
List<IntVec3> availableCells = new List<IntVec3>();
|
||||||
|
var map = Map;
|
||||||
|
if (map == null)
|
||||||
|
return availableCells;
|
||||||
|
// === 修改:使用ModExtension中定义的营养液检测半径 ===
|
||||||
|
int searchRadius = Ext.NutrientSolutionRadiusInt; // 使用ModExtension中的半径
|
||||||
|
|
||||||
|
TerrainDef nutrientDef = DefDatabase<TerrainDef>.GetNamedSilentFail("ARA_Incubator_Nutrient_Solution");
|
||||||
|
if (nutrientDef == null)
|
||||||
|
return availableCells;
|
||||||
|
// 搜索矩形区域
|
||||||
|
for (int x = -searchRadius; x <= searchRadius; x++)
|
||||||
|
{
|
||||||
|
for (int z = -searchRadius; z <= searchRadius; z++)
|
||||||
|
{
|
||||||
|
IntVec3 cell = Position + new IntVec3(x, 0, z);
|
||||||
|
// 排除自己的位置
|
||||||
|
if (cell == Position)
|
||||||
|
continue;
|
||||||
|
// 检查是否在边界内且未被消耗过
|
||||||
|
if (cell.InBounds(map) && !consumedCells.Contains(cell))
|
||||||
|
{
|
||||||
|
TerrainDef terrain = map.terrainGrid.TerrainAt(cell);
|
||||||
|
if (terrain == nutrientDef)
|
||||||
|
{
|
||||||
|
availableCells.Add(cell);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 随机排序,避免总是从固定位置开始消耗
|
||||||
|
availableCells.Shuffle();
|
||||||
|
return availableCells;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 消耗单个营养液单元格
|
||||||
|
private bool ConsumeNutrientCell(IntVec3 cell)
|
||||||
|
{
|
||||||
|
var map = Map;
|
||||||
|
if (map == null)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
// 获取目标地貌定义
|
||||||
|
TerrainDef insectCreepDef = DefDatabase<TerrainDef>.GetNamedSilentFail("ARA_InsectCreep");
|
||||||
|
TerrainDef nutrientDef = DefDatabase<TerrainDef>.GetNamedSilentFail("ARA_Incubator_Nutrient_Solution");
|
||||||
|
|
||||||
|
if (insectCreepDef == null || nutrientDef == null)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
// 记录原来的地貌
|
||||||
|
TerrainDef originalTerrain = map.terrainGrid.TerrainAt(cell);
|
||||||
|
|
||||||
|
// 转换为昆虫爬行地貌
|
||||||
|
map.terrainGrid.SetTerrain(cell, insectCreepDef);
|
||||||
|
|
||||||
|
// 检查是否有物品需要移除(如果有的话)
|
||||||
|
List<Thing> thingsAtCell = map.thingGrid.ThingsListAt(cell);
|
||||||
|
foreach (Thing thing in thingsAtCell)
|
||||||
|
{
|
||||||
|
// 如果物品阻碍了地貌转换,可能需要处理
|
||||||
|
if (thing.def.passability == Traversability.Impassable)
|
||||||
|
{
|
||||||
|
// 可以根据需要处理阻碍物
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 创建营养液蓝图
|
||||||
|
try
|
||||||
|
{
|
||||||
|
// 使用PlaceBlueprintForBuild方法创建蓝图
|
||||||
|
Blueprint_Build blueprint = GenConstruct.PlaceBlueprintForBuild(
|
||||||
|
nutrientDef,
|
||||||
|
cell,
|
||||||
|
map,
|
||||||
|
Rot4.North, // 地貌没有旋转,使用默认
|
||||||
|
Faction.OfPlayer,
|
||||||
|
null // 地貌没有stuff
|
||||||
|
);
|
||||||
|
|
||||||
|
if (blueprint != null)
|
||||||
|
{
|
||||||
|
// 显示转换效果
|
||||||
|
if (Find.TickManager.TicksGame % 10 == 0) // 每10次消耗显示一次效果
|
||||||
|
{
|
||||||
|
MoteMaker.ThrowText(cell.ToVector3Shifted(), map,
|
||||||
|
"ARA_Consumed".Translate(), Color.yellow);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
Log.Error($"Failed to place nutrient solution blueprint at {cell}: {ex.Message}");
|
||||||
|
// 如果蓝图放置失败,恢复原貌
|
||||||
|
map.terrainGrid.SetTerrain(cell, originalTerrain);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 获取营养液消耗描述
|
||||||
|
public string GetNutrientConsumptionDescription()
|
||||||
|
{
|
||||||
|
var builder = new StringBuilder();
|
||||||
|
|
||||||
|
builder.AppendLine("ARA_EquipmentIncubator.NutrientConsumption".Translate());
|
||||||
|
builder.AppendLine();
|
||||||
|
|
||||||
|
if (totalNutrientCost == 0)
|
||||||
|
{
|
||||||
|
builder.AppendLine("ARA_EquipmentIncubator.NoNutrientCost".Translate());
|
||||||
|
return builder.ToString().TrimEndNewlines();
|
||||||
|
}
|
||||||
|
|
||||||
|
builder.AppendLine("ARA_EquipmentIncubator.NutrientRequirement".Translate(totalNutrientCost));
|
||||||
|
builder.AppendLine("ARA_EquipmentIncubator.NutrientConsumed".Translate(consumedNutrientCount));
|
||||||
|
builder.AppendLine("ARA_EquipmentIncubator.NutrientProgress".Translate(NutrientProgress.ToStringPercent()));
|
||||||
|
|
||||||
|
if (HasEnoughNutrients)
|
||||||
|
{
|
||||||
|
builder.AppendLine();
|
||||||
|
builder.AppendLine("ARA_EquipmentIncubator.NutrientRequirementsMet".Translate());
|
||||||
|
}
|
||||||
|
else if (IsConsuming)
|
||||||
|
{
|
||||||
|
builder.AppendLine();
|
||||||
|
builder.AppendLine("ARA_EquipmentIncubator.ConsumingNutrients".Translate());
|
||||||
|
}
|
||||||
|
|
||||||
|
return builder.ToString().TrimEndNewlines();
|
||||||
|
}
|
||||||
|
|
||||||
// 缓存的ModExtension
|
// 缓存的ModExtension
|
||||||
private OothecaIncubatorExtension cachedExtension;
|
private OothecaIncubatorExtension cachedExtension;
|
||||||
|
|
||||||
// 获取ModExtension的辅助属性
|
// 获取ModExtension的辅助属性
|
||||||
private OothecaIncubatorExtension Ext
|
public OothecaIncubatorExtension Ext
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
@@ -263,28 +554,25 @@ namespace ArachnaeSwarm
|
|||||||
ArachnaeLog.Debug("Larva operation complete called with wrong larva.");
|
ArachnaeLog.Debug("Larva operation complete called with wrong larva.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
var config = EquipmentIncubatorData?.SelectedConfig;
|
var config = EquipmentIncubatorData?.SelectedConfig;
|
||||||
if (config == null)
|
if (config == null)
|
||||||
{
|
{
|
||||||
ArachnaeLog.Debug("No incubation config selected when larva completed operation.");
|
ArachnaeLog.Debug("No incubation config selected when larva completed operation.");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
incubatingThingDef = config.thingDef;
|
incubatingThingDef = config.thingDef;
|
||||||
incubationDuration = config.DaysRequired * 60000f;
|
incubationDuration = config.DaysRequired * 60000f;
|
||||||
incubationProgress = 0f;
|
incubationProgress = 0f;
|
||||||
isIncubating = true;
|
isIncubating = true;
|
||||||
|
|
||||||
qualityTotal = incubationDuration;
|
qualityTotal = incubationDuration;
|
||||||
qualityProgress = 0f;
|
qualityProgress = 0f;
|
||||||
UpdateQualityMultiplier();
|
UpdateQualityMultiplier();
|
||||||
|
|
||||||
UpdateSpeedMultiplier();
|
UpdateSpeedMultiplier();
|
||||||
|
|
||||||
|
// === 新增:初始化营养液消耗 ===
|
||||||
|
InitializeNutrientConsumption();
|
||||||
assignedLarva = null;
|
assignedLarva = null;
|
||||||
larvaOperateTicksRemaining = 0;
|
larvaOperateTicksRemaining = 0;
|
||||||
|
|
||||||
Messages.Message("ARA_EquipmentIncubator.IncubationStarted".Translate() + " " + incubatingThingDef.LabelCap + ". " +
|
Messages.Message("ARA_EquipmentIncubator.IncubationStarted".Translate() + " " + incubatingThingDef.LabelCap + ". " +
|
||||||
"ARA_EquipmentIncubator.ProcessWillComplete".Translate() + " " + config.DaysRequired + " " + "ARA_EquipmentIncubator.DaysBaseTime".Translate(),
|
"ARA_EquipmentIncubator.ProcessWillComplete".Translate() + " " + config.DaysRequired + " " + "ARA_EquipmentIncubator.DaysBaseTime".Translate(),
|
||||||
MessageTypeDefOf.PositiveEvent);
|
MessageTypeDefOf.PositiveEvent);
|
||||||
@@ -294,7 +582,6 @@ namespace ArachnaeSwarm
|
|||||||
private void CancelIncubation()
|
private void CancelIncubation()
|
||||||
{
|
{
|
||||||
if (!isIncubating) return;
|
if (!isIncubating) return;
|
||||||
|
|
||||||
isIncubating = false;
|
isIncubating = false;
|
||||||
incubationProgress = 0f;
|
incubationProgress = 0f;
|
||||||
incubationDuration = 0f;
|
incubationDuration = 0f;
|
||||||
@@ -302,6 +589,12 @@ namespace ArachnaeSwarm
|
|||||||
qualityProgress = 0f;
|
qualityProgress = 0f;
|
||||||
qualityTotal = 0f;
|
qualityTotal = 0f;
|
||||||
|
|
||||||
|
// === 新增:重置营养液消耗 ===
|
||||||
|
totalNutrientCost = 0;
|
||||||
|
consumedNutrientCount = 0;
|
||||||
|
hasStartedConsumption = false;
|
||||||
|
consumeProgress = 0f;
|
||||||
|
consumedCells.Clear();
|
||||||
Messages.Message("ARA_EquipmentIncubator.IncubationCancelled".Translate() + " " + "ARA_EquipmentIncubator.ContentsLost".Translate(),
|
Messages.Message("ARA_EquipmentIncubator.IncubationCancelled".Translate() + " " + "ARA_EquipmentIncubator.ContentsLost".Translate(),
|
||||||
MessageTypeDefOf.NeutralEvent);
|
MessageTypeDefOf.NeutralEvent);
|
||||||
}
|
}
|
||||||
@@ -310,19 +603,15 @@ namespace ArachnaeSwarm
|
|||||||
private void CompleteIncubation()
|
private void CompleteIncubation()
|
||||||
{
|
{
|
||||||
if (incubatingThingDef == null) return;
|
if (incubatingThingDef == null) return;
|
||||||
|
|
||||||
float finalQualityPercent = QualityPercent;
|
float finalQualityPercent = QualityPercent;
|
||||||
|
|
||||||
// 生成物品
|
// 生成物品
|
||||||
Thing thing = ThingMaker.MakeThing(incubatingThingDef);
|
Thing thing = ThingMaker.MakeThing(incubatingThingDef);
|
||||||
|
|
||||||
// 应用质量影响
|
// 应用质量影响
|
||||||
ApplyQualityEffects(thing, finalQualityPercent);
|
ApplyQualityEffects(thing, finalQualityPercent);
|
||||||
|
|
||||||
// 放置物品
|
// 放置物品
|
||||||
var spawnPos = Position;
|
var spawnPos = Position;
|
||||||
GenPlace.TryPlaceThing(thing, spawnPos, Map, ThingPlaceMode.Near);
|
GenPlace.TryPlaceThing(thing, spawnPos, Map, ThingPlaceMode.Near);
|
||||||
|
|
||||||
// 重置状态
|
// 重置状态
|
||||||
isIncubating = false;
|
isIncubating = false;
|
||||||
incubationProgress = 0f;
|
incubationProgress = 0f;
|
||||||
@@ -331,20 +620,25 @@ namespace ArachnaeSwarm
|
|||||||
qualityProgress = 0f;
|
qualityProgress = 0f;
|
||||||
qualityTotal = 0f;
|
qualityTotal = 0f;
|
||||||
|
|
||||||
|
// === 新增:清理营养液消耗状态 ===
|
||||||
|
totalNutrientCost = 0;
|
||||||
|
consumedNutrientCount = 0;
|
||||||
|
hasStartedConsumption = false;
|
||||||
|
consumeProgress = 0f;
|
||||||
|
consumedCells.Clear();
|
||||||
// 显示消息
|
// 显示消息
|
||||||
string qualityText = finalQualityPercent >= 0.9f ? "ARA_EquipmentIncubator.QualityExcellent".Translate() :
|
string qualityText = finalQualityPercent >= 0.9f ? "ARA_EquipmentIncubator.QualityExcellent".Translate() :
|
||||||
finalQualityPercent >= 0.7f ? "ARA_EquipmentIncubator.QualityGood".Translate() :
|
finalQualityPercent >= 0.7f ? "ARA_EquipmentIncubator.QualityGood".Translate() :
|
||||||
finalQualityPercent >= 0.5f ? "ARA_EquipmentIncubator.QualityAverage".Translate() :
|
finalQualityPercent >= 0.5f ? "ARA_EquipmentIncubator.QualityAverage".Translate() :
|
||||||
finalQualityPercent >= 0.3f ? "ARA_EquipmentIncubator.QualityPoor".Translate() : "ARA_EquipmentIncubator.QualityVeryPoor".Translate();
|
finalQualityPercent >= 0.3f ? "ARA_EquipmentIncubator.QualityPoor".Translate() : "ARA_EquipmentIncubator.QualityVeryPoor".Translate();
|
||||||
|
|
||||||
Messages.Message("ARA_EquipmentIncubator.IncubationComplete".Translate() + " " + thing.LabelCap + " " +
|
Messages.Message("ARA_EquipmentIncubator.IncubationComplete".Translate() + " " + thing.LabelCap + " " +
|
||||||
"ARA_EquipmentIncubator.HasEmergedWith".Translate() + " " + qualityText + " " +
|
"ARA_EquipmentIncubator.HasEmergedWith".Translate() + " " + qualityText + " " +
|
||||||
"ARA_EquipmentIncubator.Quality".Translate() + " (" + finalQualityPercent.ToStringPercent() + ").",
|
"ARA_EquipmentIncubator.Quality".Translate() + " (" + finalQualityPercent.ToStringPercent() + ").",
|
||||||
MessageTypeDefOf.PositiveEvent);
|
MessageTypeDefOf.PositiveEvent);
|
||||||
|
|
||||||
Destroy();
|
Destroy();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// 应用质量效果
|
// 应用质量效果
|
||||||
private void ApplyQualityEffects(Thing thing, float qualityPercent)
|
private void ApplyQualityEffects(Thing thing, float qualityPercent)
|
||||||
{
|
{
|
||||||
@@ -398,34 +692,44 @@ namespace ArachnaeSwarm
|
|||||||
{
|
{
|
||||||
var baseString = base.GetInspectString();
|
var baseString = base.GetInspectString();
|
||||||
var builder = new StringBuilder();
|
var builder = new StringBuilder();
|
||||||
|
|
||||||
if (!string.IsNullOrEmpty(baseString))
|
if (!string.IsNullOrEmpty(baseString))
|
||||||
{
|
{
|
||||||
builder.Append(baseString);
|
builder.Append(baseString);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isIncubating && incubatingThingDef != null)
|
if (isIncubating && incubatingThingDef != null)
|
||||||
{
|
{
|
||||||
float progressPercent = AdjustedProgressPercent;
|
float progressPercent = AdjustedProgressPercent;
|
||||||
float daysRemaining = GetRemainingDays();
|
float daysRemaining = GetRemainingDays();
|
||||||
float hoursRemaining = GetRemainingHours();
|
float hoursRemaining = GetRemainingHours();
|
||||||
|
|
||||||
if (builder.Length > 0) builder.AppendLine();
|
if (builder.Length > 0) builder.AppendLine();
|
||||||
builder.Append("ARA_EquipmentIncubator.Incubating".Translate() + ": " + incubatingThingDef.LabelCap);
|
builder.Append("ARA_EquipmentIncubator.Incubating".Translate() + ": " + incubatingThingDef.LabelCap);
|
||||||
builder.AppendLine();
|
builder.AppendLine();
|
||||||
builder.Append("ARA_EquipmentIncubator.Progress".Translate() + ": " + progressPercent.ToStringPercent());
|
builder.Append("ARA_EquipmentIncubator.Progress".Translate() + ": " + progressPercent.ToStringPercent());
|
||||||
builder.AppendLine();
|
builder.AppendLine();
|
||||||
|
|
||||||
string timeText = "ARA_EquipmentIncubator.TimeRemaining".Translate() + ": " + daysRemaining.ToString("F1") + " " + "ARA_EquipmentIncubator.Days".Translate();
|
string timeText = "ARA_EquipmentIncubator.TimeRemaining".Translate() + ": " + daysRemaining.ToString("F1") + " " + "ARA_EquipmentIncubator.Days".Translate();
|
||||||
if (hoursRemaining > 0.1f && daysRemaining < 1f)
|
if (hoursRemaining > 0.1f && daysRemaining < 1f)
|
||||||
{
|
{
|
||||||
timeText += " (" + hoursRemaining.ToString("F1") + " " + "ARA_EquipmentIncubator.Hours".Translate() + ")";
|
timeText += " (" + hoursRemaining.ToString("F1") + " " + "ARA_EquipmentIncubator.Hours".Translate() + ")";
|
||||||
}
|
}
|
||||||
builder.Append(timeText);
|
builder.Append(timeText);
|
||||||
|
|
||||||
builder.AppendLine();
|
builder.AppendLine();
|
||||||
builder.Append("ARA_EquipmentIncubator.Speed".Translate() + ": " + SpeedMultiplier.ToStringPercent() + ", " +
|
builder.Append("ARA_EquipmentIncubator.Speed".Translate() + ": " + SpeedMultiplier.ToStringPercent() + ", " +
|
||||||
"ARA_EquipmentIncubator.Quality".Translate() + ": " + QualityMultiplier.ToStringPercent());
|
"ARA_EquipmentIncubator.Quality".Translate() + ": " + QualityMultiplier.ToStringPercent());
|
||||||
|
|
||||||
|
// === 新增:显示营养液消耗信息 ===
|
||||||
|
if (totalNutrientCost > 0)
|
||||||
|
{
|
||||||
|
builder.AppendLine();
|
||||||
|
builder.Append("ARA_EquipmentIncubator.NutrientConsumption".Translate() + ": " +
|
||||||
|
consumedNutrientCount + " / " + totalNutrientCost +
|
||||||
|
" (" + NutrientProgress.ToStringPercent() + ")");
|
||||||
|
|
||||||
|
if (!HasEnoughNutrients && IsConsuming)
|
||||||
|
{
|
||||||
|
builder.AppendLine();
|
||||||
|
builder.Append("ARA_EquipmentIncubator.ConsumingNutrients".Translate());
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (assignedLarva != null)
|
else if (assignedLarva != null)
|
||||||
{
|
{
|
||||||
@@ -447,13 +751,23 @@ namespace ArachnaeSwarm
|
|||||||
{
|
{
|
||||||
if (builder.Length > 0) builder.AppendLine();
|
if (builder.Length > 0) builder.AppendLine();
|
||||||
builder.Append("ARA_EquipmentIncubator.Target".Translate() + ": " + config.thingDef.LabelCap);
|
builder.Append("ARA_EquipmentIncubator.Target".Translate() + ": " + config.thingDef.LabelCap);
|
||||||
|
|
||||||
builder.AppendLine();
|
builder.AppendLine();
|
||||||
builder.Append("ARA_EquipmentIncubator.SpeedMultiplier".Translate() + ": " + SpeedMultiplier.ToStringPercent() + ", " +
|
builder.Append("ARA_EquipmentIncubator.SpeedMultiplier".Translate() + ": " + SpeedMultiplier.ToStringPercent() + ", " +
|
||||||
"ARA_EquipmentIncubator.QualityMultiplier".Translate() + ": " + QualityMultiplier.ToStringPercent());
|
"ARA_EquipmentIncubator.QualityMultiplier".Translate() + ": " + QualityMultiplier.ToStringPercent());
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
// === 新增:显示预计的营养液需求 ===
|
||||||
|
var costStat = DefDatabase<StatDef>.GetNamedSilentFail("ARA_IncubationCost");
|
||||||
|
if (costStat != null)
|
||||||
|
{
|
||||||
|
int estimatedCost = Mathf.RoundToInt(config.thingDef.GetStatValueAbstract(costStat, null));
|
||||||
|
if (estimatedCost > 0)
|
||||||
|
{
|
||||||
|
builder.AppendLine();
|
||||||
|
builder.Append("ARA_EquipmentIncubator.EstimatedNutrientCost".Translate() + ": " + estimatedCost);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
return builder.ToString().TrimEndNewlines();
|
return builder.ToString().TrimEndNewlines();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -720,6 +1034,7 @@ namespace ArachnaeSwarm
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 每tick更新
|
// 每tick更新
|
||||||
|
// 修改Tick方法,处理营养液不足时停止孵化的逻辑
|
||||||
protected override void Tick()
|
protected override void Tick()
|
||||||
{
|
{
|
||||||
base.Tick();
|
base.Tick();
|
||||||
@@ -738,9 +1053,47 @@ namespace ArachnaeSwarm
|
|||||||
}
|
}
|
||||||
|
|
||||||
float currentSpeed = SpeedMultiplier;
|
float currentSpeed = SpeedMultiplier;
|
||||||
incubationProgress += currentSpeed;
|
|
||||||
|
|
||||||
|
// === 新增:检查是否因营养液不足而停止孵化 ===
|
||||||
|
bool shouldProgress = true;
|
||||||
|
|
||||||
|
if (Ext.stopIncubationWhenNutrientDeficient &&
|
||||||
|
!HasEnoughNutrients &&
|
||||||
|
isIncubating &&
|
||||||
|
hasStartedConsumption)
|
||||||
|
{
|
||||||
|
// 检查是否有可用的营养液
|
||||||
|
var availableCells = FindNutrientCells();
|
||||||
|
if (availableCells.Count == 0 && totalNutrientCost > 0 && consumedNutrientCount < totalNutrientCost)
|
||||||
|
{
|
||||||
|
shouldProgress = false;
|
||||||
|
|
||||||
|
// 显示停止消息(第一次或偶尔显示)
|
||||||
|
if (Find.TickManager.TicksGame % 1000 == 0 && Rand.Chance(0.1f))
|
||||||
|
{
|
||||||
|
Messages.Message("ARA_EquipmentIncubator.IncubationPausedNoNutrients".Translate(incubatingThingDef?.LabelCap ?? "Unknown"),
|
||||||
|
this, MessageTypeDefOf.NeutralEvent);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (shouldProgress)
|
||||||
|
{
|
||||||
|
incubationProgress += currentSpeed;
|
||||||
qualityProgress += currentSpeed * QualityMultiplier;
|
qualityProgress += currentSpeed * QualityMultiplier;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// 孵化暂停,但仍然需要检查营养液消耗(可能营养液又出现了)
|
||||||
|
// 并且仍然应用伤害
|
||||||
|
}
|
||||||
|
|
||||||
|
// === 新增:检查营养液消耗 ===
|
||||||
|
if (lastConsumeCheckTick < 0 || Find.TickManager.TicksGame - lastConsumeCheckTick >= ConsumeCheckInterval)
|
||||||
|
{
|
||||||
|
lastConsumeCheckTick = Find.TickManager.TicksGame;
|
||||||
|
CheckAndConsumeNutrients();
|
||||||
|
}
|
||||||
|
|
||||||
if (incubationProgress >= incubationDuration)
|
if (incubationProgress >= incubationDuration)
|
||||||
{
|
{
|
||||||
@@ -912,6 +1265,21 @@ namespace ArachnaeSwarm
|
|||||||
Scribe_Values.Look(ref qualityMultiplier, "qualityMultiplier", 1.0f);
|
Scribe_Values.Look(ref qualityMultiplier, "qualityMultiplier", 1.0f);
|
||||||
Scribe_Values.Look(ref qualityProgress, "qualityProgress", 0f);
|
Scribe_Values.Look(ref qualityProgress, "qualityProgress", 0f);
|
||||||
Scribe_Values.Look(ref qualityTotal, "qualityTotal", 0f);
|
Scribe_Values.Look(ref qualityTotal, "qualityTotal", 0f);
|
||||||
|
|
||||||
|
// === 新增:保存营养液消耗状态 ===
|
||||||
|
Scribe_Values.Look(ref totalNutrientCost, "totalNutrientCost", 0);
|
||||||
|
Scribe_Values.Look(ref consumedNutrientCount, "consumedNutrientCount", 0);
|
||||||
|
Scribe_Values.Look(ref lastConsumeCheckTick, "lastConsumeCheckTick", -1);
|
||||||
|
Scribe_Values.Look(ref hasStartedConsumption, "hasStartedConsumption", false);
|
||||||
|
Scribe_Values.Look(ref consumeProgress, "consumeProgress", 0f);
|
||||||
|
Scribe_Collections.Look(ref consumedCells, "consumedCells", LookMode.Value);
|
||||||
|
|
||||||
|
if (Scribe.mode == LoadSaveMode.PostLoadInit)
|
||||||
|
{
|
||||||
|
// 确保列表不为null
|
||||||
|
if (consumedCells == null)
|
||||||
|
consumedCells = new List<IntVec3>();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,10 +15,10 @@ namespace ArachnaeSwarm
|
|||||||
private const float SmallLabelHeight = 20f;
|
private const float SmallLabelHeight = 20f;
|
||||||
private const float ButtonHeight = 25f;
|
private const float ButtonHeight = 25f;
|
||||||
private const float TabWidth = 320f;
|
private const float TabWidth = 320f;
|
||||||
private const float TabHeight = 420f;
|
private const float TabHeight = 450f; // 增加高度以容纳更多信息
|
||||||
|
|
||||||
private Vector2 scrollPosition = Vector2.zero;
|
private Vector2 scrollPosition = Vector2.zero;
|
||||||
private const float ViewHeight = 450f;
|
private const float ViewHeight = 480f; // 增加视图高度
|
||||||
|
|
||||||
public override bool IsVisible
|
public override bool IsVisible
|
||||||
{
|
{
|
||||||
@@ -46,12 +46,9 @@ namespace ArachnaeSwarm
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
rect = rect.ContractedBy(5f);
|
rect = rect.ContractedBy(5f);
|
||||||
|
|
||||||
Rect viewRect = new Rect(0f, 0f, rect.width - 16f, ViewHeight);
|
Rect viewRect = new Rect(0f, 0f, rect.width - 16f, ViewHeight);
|
||||||
Rect scrollRect = new Rect(rect.x, rect.y, rect.width, rect.height);
|
Rect scrollRect = new Rect(rect.x, rect.y, rect.width, rect.height);
|
||||||
|
|
||||||
Widgets.BeginScrollView(scrollRect, ref scrollPosition, viewRect);
|
Widgets.BeginScrollView(scrollRect, ref scrollPosition, viewRect);
|
||||||
|
|
||||||
float curY = 0f;
|
float curY = 0f;
|
||||||
|
|
||||||
Rect titleRect = new Rect(0f, curY, viewRect.width, LabelHeight);
|
Rect titleRect = new Rect(0f, curY, viewRect.width, LabelHeight);
|
||||||
@@ -144,7 +141,97 @@ namespace ArachnaeSwarm
|
|||||||
Text.Anchor = TextAnchor.UpperLeft;
|
Text.Anchor = TextAnchor.UpperLeft;
|
||||||
GUI.color = Color.white;
|
GUI.color = Color.white;
|
||||||
|
|
||||||
Widgets.FillableBar(qualityBarRect, qualityPercent, SolidColorMaterials.NewSolidColorTexture(new Color(0.1f, 0.4f, 0.8f, 0.5f)));
|
Widgets.FillableBar(qualityBarRect, qualityPercent, SolidColorMaterials.NewSolidColorTexture(new Color(0.1f, 0.4f, 0.8f, 0.5f))); curY += BarHeight + 25f;
|
||||||
|
|
||||||
|
// === 新增:营养液消耗显示 ===
|
||||||
|
if (ootheca.TotalNutrientCost > 0)
|
||||||
|
{
|
||||||
|
// 标题
|
||||||
|
Rect nutrientTitleRect = new Rect(0f, curY, viewRect.width, SmallLabelHeight);
|
||||||
|
Widgets.Label(nutrientTitleRect, "ARA_EquipmentIncubator.NutrientConsumption".Translate());
|
||||||
|
curY += SmallLabelHeight + 5f;
|
||||||
|
|
||||||
|
// 进度条
|
||||||
|
Rect nutrientBarRect = new Rect(0f, curY, viewRect.width, BarHeight);
|
||||||
|
float nutrientProgress = ootheca.NutrientProgress;
|
||||||
|
|
||||||
|
Widgets.FillableBar(nutrientBarRect, nutrientProgress,
|
||||||
|
SolidColorMaterials.NewSolidColorTexture(new Color(0.8f, 0.6f, 0.1f, 0.5f)));
|
||||||
|
|
||||||
|
// 进度文本
|
||||||
|
string nutrientText = $"{ootheca.ConsumedNutrientCount} / {ootheca.TotalNutrientCost} ({nutrientProgress:P0})";
|
||||||
|
Text.Anchor = TextAnchor.MiddleCenter;
|
||||||
|
Widgets.Label(nutrientBarRect, nutrientText);
|
||||||
|
Text.Anchor = TextAnchor.UpperLeft;
|
||||||
|
|
||||||
|
curY += BarHeight + 10f;
|
||||||
|
|
||||||
|
// 状态描述
|
||||||
|
Rect nutrientStatusRect = new Rect(0f, curY, viewRect.width, SmallLabelHeight);
|
||||||
|
string statusText;
|
||||||
|
if (ootheca.HasEnoughNutrients)
|
||||||
|
{
|
||||||
|
statusText = "ARA_EquipmentIncubator.NutrientRequirementsMet".Translate();
|
||||||
|
GUI.color = Color.green;
|
||||||
|
}
|
||||||
|
else if (ootheca.IsConsuming)
|
||||||
|
{
|
||||||
|
statusText = "ARA_EquipmentIncubator.ConsumingNutrients".Translate();
|
||||||
|
GUI.color = Color.yellow;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
statusText = "ARA_EquipmentIncubator.WaitingForNutrients".Translate();
|
||||||
|
GUI.color = Color.gray;
|
||||||
|
}
|
||||||
|
|
||||||
|
Widgets.Label(nutrientStatusRect, statusText);
|
||||||
|
GUI.color = Color.white;
|
||||||
|
|
||||||
|
curY += SmallLabelHeight + 15f;
|
||||||
|
}
|
||||||
|
// === 新增:营养液不足状态显示 ===
|
||||||
|
if (ootheca.TotalNutrientCost > 0 && ootheca.IsConsuming)
|
||||||
|
{
|
||||||
|
curY += BarHeight + 15f;
|
||||||
|
|
||||||
|
// 检查是否有营养液不足的警告
|
||||||
|
var availableCells = ootheca.FindNutrientCells();
|
||||||
|
if (availableCells.Count == 0 && !ootheca.HasEnoughNutrients)
|
||||||
|
{
|
||||||
|
Rect warningRect = new Rect(0f, curY, viewRect.width, SmallLabelHeight * 2);
|
||||||
|
|
||||||
|
if (ootheca.Ext.stopIncubationWhenNutrientDeficient)
|
||||||
|
{
|
||||||
|
Widgets.Label(warningRect, "ARA_EquipmentIncubator.IncubationPausedWarning".Translate());
|
||||||
|
GUI.color = Color.yellow;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Widgets.Label(warningRect, "ARA_EquipmentIncubator.NutrientDeficiencyWarning".Translate());
|
||||||
|
GUI.color = Color.red;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 绘制警告背景
|
||||||
|
Widgets.DrawHighlight(warningRect);
|
||||||
|
GUI.color = Color.white;
|
||||||
|
|
||||||
|
curY += SmallLabelHeight * 2 + 10f;
|
||||||
|
|
||||||
|
// 显示血量警告
|
||||||
|
float healthPercent = (float)ootheca.HitPoints / ootheca.MaxHitPoints;
|
||||||
|
if (healthPercent < 0.5f)
|
||||||
|
{
|
||||||
|
Rect healthWarningRect = new Rect(0f, curY, viewRect.width, SmallLabelHeight);
|
||||||
|
Widgets.Label(healthWarningRect, "ARA_EquipmentIncubator.LowHealthWarning".Translate(healthPercent.ToStringPercent()));
|
||||||
|
GUI.color = new Color(1f, 0.5f, 0.5f);
|
||||||
|
Widgets.DrawHighlight(healthWarningRect);
|
||||||
|
GUI.color = Color.white;
|
||||||
|
|
||||||
|
curY += SmallLabelHeight + 5f;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
string qualityProgressText = $"{qualityPercent:P0}";
|
string qualityProgressText = $"{qualityPercent:P0}";
|
||||||
Text.Anchor = TextAnchor.MiddleCenter;
|
Text.Anchor = TextAnchor.MiddleCenter;
|
||||||
|
|||||||
@@ -302,23 +302,18 @@ namespace ArachnaeSwarm
|
|||||||
private void CompleteIncubation()
|
private void CompleteIncubation()
|
||||||
{
|
{
|
||||||
if (incubatingPawnKind == null) return;
|
if (incubatingPawnKind == null) return;
|
||||||
|
|
||||||
// 计算最终质量百分比
|
// 计算最终质量百分比
|
||||||
float finalQualityPercent = QualityPercent;
|
float finalQualityPercent = QualityPercent;
|
||||||
|
|
||||||
// 生成新的pawn
|
// 生成新的pawn
|
||||||
var pawn = PawnGenerator.GeneratePawn(incubatingPawnKind, Faction);
|
var pawn = PawnGenerator.GeneratePawn(incubatingPawnKind, Faction);
|
||||||
|
// 应用质量影响(包括Hediff奖励)
|
||||||
// 应用质量影响
|
|
||||||
ApplyQualityEffects(pawn, finalQualityPercent);
|
ApplyQualityEffects(pawn, finalQualityPercent);
|
||||||
|
|
||||||
// 尝试将pawn放置在地图上
|
// 尝试将pawn放置在地图上
|
||||||
var spawnPos = Position;
|
var spawnPos = Position;
|
||||||
if (!pawn.Spawned)
|
if (!pawn.Spawned)
|
||||||
{
|
{
|
||||||
GenSpawn.Spawn(pawn, spawnPos, Map);
|
GenSpawn.Spawn(pawn, spawnPos, Map);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 重置孵化状态
|
// 重置孵化状态
|
||||||
isIncubating = false;
|
isIncubating = false;
|
||||||
incubationProgress = 0f;
|
incubationProgress = 0f;
|
||||||
@@ -326,18 +321,15 @@ namespace ArachnaeSwarm
|
|||||||
incubatingPawnKind = null;
|
incubatingPawnKind = null;
|
||||||
qualityProgress = 0f;
|
qualityProgress = 0f;
|
||||||
qualityTotal = 0f;
|
qualityTotal = 0f;
|
||||||
|
|
||||||
// 显示消息
|
// 显示消息
|
||||||
string qualityText = finalQualityPercent >= 0.9f ? "ARA_OothecaIncubator.QualityExcellent".Translate() :
|
string qualityText = finalQualityPercent >= 0.9f ? "ARA_OothecaIncubator.QualityExcellent".Translate() :
|
||||||
finalQualityPercent >= 0.7f ? "ARA_OothecaIncubator.QualityGood".Translate() :
|
finalQualityPercent >= 0.7f ? "ARA_OothecaIncubator.QualityGood".Translate() :
|
||||||
finalQualityPercent >= 0.5f ? "ARA_OothecaIncubator.QualityAverage".Translate() :
|
finalQualityPercent >= 0.5f ? "ARA_OothecaIncubator.QualityAverage".Translate() :
|
||||||
finalQualityPercent >= 0.3f ? "ARA_OothecaIncubator.QualityPoor".Translate() : "ARA_OothecaIncubator.QualityVeryPoor".Translate();
|
finalQualityPercent >= 0.3f ? "ARA_OothecaIncubator.QualityPoor".Translate() : "ARA_OothecaIncubator.QualityVeryPoor".Translate();
|
||||||
|
|
||||||
Messages.Message("ARA_OothecaIncubator.IncubationComplete".Translate() + " " + pawn.LabelCap + " " +
|
Messages.Message("ARA_OothecaIncubator.IncubationComplete".Translate() + " " + pawn.LabelCap + " " +
|
||||||
"ARA_OothecaIncubator.HasEmergedWith".Translate() + " " + qualityText + " " +
|
"ARA_OothecaIncubator.HasEmergedWith".Translate() + " " + qualityText + " " +
|
||||||
"ARA_OothecaIncubator.Quality".Translate() + " (" + finalQualityPercent.ToStringPercent() + ").",
|
"ARA_OothecaIncubator.Quality".Translate() + " (" + finalQualityPercent.ToStringPercent() + ").",
|
||||||
MessageTypeDefOf.PositiveEvent);
|
MessageTypeDefOf.PositiveEvent);
|
||||||
|
|
||||||
Destroy();
|
Destroy();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -712,8 +704,52 @@ namespace ArachnaeSwarm
|
|||||||
// 应用质量效果到生成的pawn
|
// 应用质量效果到生成的pawn
|
||||||
private void ApplyQualityEffects(Pawn pawn, float qualityPercent)
|
private void ApplyQualityEffects(Pawn pawn, float qualityPercent)
|
||||||
{
|
{
|
||||||
// 质量影响:根据质量百分比调整pawn的属性
|
ApplyHediffRewards(pawn, qualityPercent);
|
||||||
// 这里可以添加具体的质量效果逻辑
|
}
|
||||||
|
// === 新增:应用Hediff奖励方法 ===
|
||||||
|
private void ApplyHediffRewards(Pawn pawn, float qualityPercent)
|
||||||
|
{
|
||||||
|
var config = IncubatorData?.SelectedConfig;
|
||||||
|
if (config == null) return;
|
||||||
|
|
||||||
|
// 获取应奖励的Hediff列表
|
||||||
|
List<HediffDef> rewardHediffs = config.GetRewardHediffs(qualityPercent);
|
||||||
|
if (rewardHediffs == null || rewardHediffs.Count == 0) return;
|
||||||
|
|
||||||
|
// 应用Hediff
|
||||||
|
int appliedCount = 0;
|
||||||
|
foreach (var hediffDef in rewardHediffs)
|
||||||
|
{
|
||||||
|
if (hediffDef == null) continue;
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
// 检查pawn是否已经有这个Hediff(避免重复)
|
||||||
|
if (!pawn.health.hediffSet.HasHediff(hediffDef))
|
||||||
|
{
|
||||||
|
// 创建并添加Hediff
|
||||||
|
Hediff hediff = HediffMaker.MakeHediff(hediffDef, pawn);
|
||||||
|
pawn.health.AddHediff(hediff);
|
||||||
|
appliedCount++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (System.Exception ex)
|
||||||
|
{
|
||||||
|
Log.Error($"Failed to apply hediff {hediffDef?.defName} to pawn {pawn.Label}: {ex.Message}");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 显示奖励消息
|
||||||
|
if (appliedCount > 0)
|
||||||
|
{
|
||||||
|
string message = config.GetRewardMessage(qualityPercent);
|
||||||
|
if (string.IsNullOrEmpty(message))
|
||||||
|
{
|
||||||
|
message = "ARA_QualityReward_Default".Translate(pawn.LabelShortCap, appliedCount);
|
||||||
|
}
|
||||||
|
|
||||||
|
Messages.Message(message, pawn, MessageTypeDefOf.PositiveEvent);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 检查是否在孵化间中
|
// 检查是否在孵化间中
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
// File: Comps/CompProperties_IncubatorData.cs
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using RimWorld;
|
using RimWorld;
|
||||||
@@ -6,6 +7,40 @@ using Verse;
|
|||||||
|
|
||||||
namespace ArachnaeSwarm
|
namespace ArachnaeSwarm
|
||||||
{
|
{
|
||||||
|
// 质量阈值和Hediff奖励配置
|
||||||
|
public class QualityHediffReward : IExposable
|
||||||
|
{
|
||||||
|
// 质量阈值(0-1)
|
||||||
|
public float qualityThreshold = 0f;
|
||||||
|
|
||||||
|
// 达到该阈值时给予的Hediff数量
|
||||||
|
public int hediffCount = 0;
|
||||||
|
|
||||||
|
// 是否给予全部Hediff(true=给予列表中所有Hediff,false=随机选择指定数量的Hediff)
|
||||||
|
public bool giveAllHediffs = false;
|
||||||
|
|
||||||
|
// 消息文本(可选)
|
||||||
|
public string messageKey = null;
|
||||||
|
|
||||||
|
public QualityHediffReward() { }
|
||||||
|
|
||||||
|
public QualityHediffReward(float threshold, int count, bool giveAll = false, string message = null)
|
||||||
|
{
|
||||||
|
qualityThreshold = threshold;
|
||||||
|
hediffCount = count;
|
||||||
|
giveAllHediffs = giveAll;
|
||||||
|
messageKey = message;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void ExposeData()
|
||||||
|
{
|
||||||
|
Scribe_Values.Look(ref qualityThreshold, "qualityThreshold", 0f);
|
||||||
|
Scribe_Values.Look(ref hediffCount, "hediffCount", 0);
|
||||||
|
Scribe_Values.Look(ref giveAllHediffs, "giveAllHediffs", false);
|
||||||
|
Scribe_Values.Look(ref messageKey, "messageKey");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// IncubationConfig 保持不变
|
// IncubationConfig 保持不变
|
||||||
public class IncubationConfig : IExposable
|
public class IncubationConfig : IExposable
|
||||||
{
|
{
|
||||||
@@ -14,6 +49,10 @@ namespace ArachnaeSwarm
|
|||||||
public float daysRequired;
|
public float daysRequired;
|
||||||
public string buttonIconPath;
|
public string buttonIconPath;
|
||||||
|
|
||||||
|
// === 新增:每个配置可以有自己的Hediff奖励列表 ===
|
||||||
|
public List<HediffDef> extraHediffs = new List<HediffDef>();
|
||||||
|
public List<QualityHediffReward> hediffRewards = new List<QualityHediffReward>();
|
||||||
|
|
||||||
public IncubationConfig() { }
|
public IncubationConfig() { }
|
||||||
|
|
||||||
public IncubationConfig(PawnKindDef pawnKind, ResearchProjectDef requiredResearch = null,
|
public IncubationConfig(PawnKindDef pawnKind, ResearchProjectDef requiredResearch = null,
|
||||||
@@ -23,6 +62,20 @@ namespace ArachnaeSwarm
|
|||||||
this.requiredResearch = requiredResearch;
|
this.requiredResearch = requiredResearch;
|
||||||
this.daysRequired = daysRequired;
|
this.daysRequired = daysRequired;
|
||||||
this.buttonIconPath = buttonIconPath;
|
this.buttonIconPath = buttonIconPath;
|
||||||
|
extraHediffs = new List<HediffDef>();
|
||||||
|
hediffRewards = CreateDefaultRewards(); // 创建默认奖励配置
|
||||||
|
}
|
||||||
|
|
||||||
|
// 创建默认奖励配置(30%、50%、85%、99%阈值)
|
||||||
|
private List<QualityHediffReward> CreateDefaultRewards()
|
||||||
|
{
|
||||||
|
return new List<QualityHediffReward>
|
||||||
|
{
|
||||||
|
new QualityHediffReward(0.30f, 1, false, "ARA_QualityReward_1Hediff"),
|
||||||
|
new QualityHediffReward(0.50f, 2, false, "ARA_QualityReward_2Hediff"),
|
||||||
|
new QualityHediffReward(0.85f, 3, false, "ARA_QualityReward_3Hediff"),
|
||||||
|
new QualityHediffReward(0.99f, 4, true, "ARA_QualityReward_AllHediff")
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
public void ExposeData()
|
public void ExposeData()
|
||||||
@@ -31,12 +84,24 @@ namespace ArachnaeSwarm
|
|||||||
Scribe_Defs.Look(ref requiredResearch, "requiredResearch");
|
Scribe_Defs.Look(ref requiredResearch, "requiredResearch");
|
||||||
Scribe_Values.Look(ref daysRequired, "daysRequired", 1f);
|
Scribe_Values.Look(ref daysRequired, "daysRequired", 1f);
|
||||||
Scribe_Values.Look(ref buttonIconPath, "buttonIconPath");
|
Scribe_Values.Look(ref buttonIconPath, "buttonIconPath");
|
||||||
|
|
||||||
|
// === 新增:保存Hediff相关数据 ===
|
||||||
|
Scribe_Collections.Look(ref extraHediffs, "extraHediffs", LookMode.Def);
|
||||||
|
Scribe_Collections.Look(ref hediffRewards, "hediffRewards", LookMode.Deep);
|
||||||
|
|
||||||
|
if (Scribe.mode == LoadSaveMode.PostLoadInit)
|
||||||
|
{
|
||||||
|
if (extraHediffs == null)
|
||||||
|
extraHediffs = new List<HediffDef>();
|
||||||
|
if (hediffRewards == null)
|
||||||
|
hediffRewards = CreateDefaultRewards();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 检查是否满足研究要求
|
// 检查是否满足研究要求
|
||||||
public bool IsResearchComplete => requiredResearch == null || requiredResearch.IsFinished;
|
public bool IsResearchComplete => requiredResearch == null || requiredResearch.IsFinished;
|
||||||
|
|
||||||
// 在配置描述中使用翻译
|
// 获取描述 - 添加Hediff奖励信息
|
||||||
public string GetDescription()
|
public string GetDescription()
|
||||||
{
|
{
|
||||||
var builder = new StringBuilder();
|
var builder = new StringBuilder();
|
||||||
@@ -52,8 +117,127 @@ namespace ArachnaeSwarm
|
|||||||
builder.AppendLine("Research".Translate() + ": " + requiredResearch.LabelCap + " (" + "Required".Translate() + ")");
|
builder.AppendLine("Research".Translate() + ": " + requiredResearch.LabelCap + " (" + "Required".Translate() + ")");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// === 新增:显示Hediff奖励信息 ===
|
||||||
|
if (extraHediffs != null && extraHediffs.Count > 0)
|
||||||
|
{
|
||||||
|
builder.AppendLine();
|
||||||
|
builder.AppendLine("HediffRewards".Translate() + ":");
|
||||||
|
|
||||||
|
foreach (var hediff in extraHediffs)
|
||||||
|
{
|
||||||
|
if (hediff != null)
|
||||||
|
{
|
||||||
|
builder.AppendLine(" - " + hediff.LabelCap);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 显示质量阈值信息
|
||||||
|
if (hediffRewards != null && hediffRewards.Count > 0)
|
||||||
|
{
|
||||||
|
builder.AppendLine();
|
||||||
|
builder.AppendLine("QualityThresholds".Translate() + ":");
|
||||||
|
foreach (var reward in hediffRewards)
|
||||||
|
{
|
||||||
|
if (reward.qualityThreshold > 0 && reward.hediffCount > 0)
|
||||||
|
{
|
||||||
|
string rewardText = $" {reward.qualityThreshold:P0}: ";
|
||||||
|
if (reward.giveAllHediffs)
|
||||||
|
{
|
||||||
|
rewardText += "AllHediffsReward".Translate();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
rewardText += "HediffCountReward".Translate(reward.hediffCount);
|
||||||
|
}
|
||||||
|
builder.AppendLine(rewardText);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return builder.ToString().TrimEndNewlines();
|
return builder.ToString().TrimEndNewlines();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// === 新增:获取应给予的Hediff数量 ===
|
||||||
|
public int GetHediffCountForQuality(float qualityPercent)
|
||||||
|
{
|
||||||
|
if (hediffRewards == null || hediffRewards.Count == 0)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
// 按阈值降序排序,找到第一个满足条件的奖励
|
||||||
|
var sortedRewards = new List<QualityHediffReward>(hediffRewards);
|
||||||
|
sortedRewards.Sort((a, b) => b.qualityThreshold.CompareTo(a.qualityThreshold));
|
||||||
|
|
||||||
|
foreach (var reward in sortedRewards)
|
||||||
|
{
|
||||||
|
if (qualityPercent >= reward.qualityThreshold)
|
||||||
|
{
|
||||||
|
if (reward.giveAllHediffs)
|
||||||
|
{
|
||||||
|
return extraHediffs != null ? extraHediffs.Count : 0;
|
||||||
|
}
|
||||||
|
return reward.hediffCount;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
// === 新增:获取奖励的Hediff列表 ===
|
||||||
|
public List<HediffDef> GetRewardHediffs(float qualityPercent)
|
||||||
|
{
|
||||||
|
int count = GetHediffCountForQuality(qualityPercent);
|
||||||
|
if (count <= 0 || extraHediffs == null || extraHediffs.Count == 0)
|
||||||
|
return new List<HediffDef>();
|
||||||
|
|
||||||
|
// 如果要求给予所有Hediff,返回全部
|
||||||
|
var sortedRewards = new List<QualityHediffReward>(hediffRewards);
|
||||||
|
sortedRewards.Sort((a, b) => b.qualityThreshold.CompareTo(a.qualityThreshold));
|
||||||
|
|
||||||
|
foreach (var reward in sortedRewards)
|
||||||
|
{
|
||||||
|
if (qualityPercent >= reward.qualityThreshold && reward.giveAllHediffs)
|
||||||
|
{
|
||||||
|
return new List<HediffDef>(extraHediffs);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 否则随机选择指定数量的Hediff(不重复)
|
||||||
|
List<HediffDef> result = new List<HediffDef>();
|
||||||
|
List<HediffDef> available = new List<HediffDef>(extraHediffs);
|
||||||
|
|
||||||
|
count = Mathf.Min(count, available.Count);
|
||||||
|
for (int i = 0; i < count; i++)
|
||||||
|
{
|
||||||
|
if (available.Count == 0) break;
|
||||||
|
|
||||||
|
int index = Rand.Range(0, available.Count);
|
||||||
|
result.Add(available[index]);
|
||||||
|
available.RemoveAt(index);
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
// === 新增:获取奖励消息 ===
|
||||||
|
public string GetRewardMessage(float qualityPercent)
|
||||||
|
{
|
||||||
|
if (hediffRewards == null || hediffRewards.Count == 0)
|
||||||
|
return null;
|
||||||
|
|
||||||
|
var sortedRewards = new List<QualityHediffReward>(hediffRewards);
|
||||||
|
sortedRewards.Sort((a, b) => b.qualityThreshold.CompareTo(a.qualityThreshold));
|
||||||
|
|
||||||
|
foreach (var reward in sortedRewards)
|
||||||
|
{
|
||||||
|
if (qualityPercent >= reward.qualityThreshold && !string.IsNullOrEmpty(reward.messageKey))
|
||||||
|
{
|
||||||
|
return reward.messageKey.Translate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 组件属性定义
|
// 组件属性定义
|
||||||
@@ -70,6 +254,10 @@ namespace ArachnaeSwarm
|
|||||||
public string menuTitle = "IncubatorMenuTitle"; // 菜单标题翻译键
|
public string menuTitle = "IncubatorMenuTitle"; // 菜单标题翻译键
|
||||||
public string defaultIconPath = "UI/Commands/Default";
|
public string defaultIconPath = "UI/Commands/Default";
|
||||||
|
|
||||||
|
// === 新增:全局Hediff奖励(所有配置共享)===
|
||||||
|
public List<HediffDef> globalExtraHediffs = new List<HediffDef>();
|
||||||
|
public List<QualityHediffReward> globalHediffRewards = new List<QualityHediffReward>();
|
||||||
|
|
||||||
public CompProperties_IncubatorData()
|
public CompProperties_IncubatorData()
|
||||||
{
|
{
|
||||||
compClass = typeof(CompIncubatorData);
|
compClass = typeof(CompIncubatorData);
|
||||||
@@ -80,6 +268,67 @@ namespace ArachnaeSwarm
|
|||||||
base.ResolveReferences(parentDef);
|
base.ResolveReferences(parentDef);
|
||||||
if (incubationConfigs == null)
|
if (incubationConfigs == null)
|
||||||
incubationConfigs = new List<IncubationConfig>();
|
incubationConfigs = new List<IncubationConfig>();
|
||||||
|
if (globalExtraHediffs == null)
|
||||||
|
globalExtraHediffs = new List<HediffDef>();
|
||||||
|
if (globalHediffRewards == null)
|
||||||
|
globalHediffRewards = CreateDefaultGlobalRewards();
|
||||||
|
}
|
||||||
|
|
||||||
|
// 创建默认的全局奖励配置
|
||||||
|
private List<QualityHediffReward> CreateDefaultGlobalRewards()
|
||||||
|
{
|
||||||
|
return new List<QualityHediffReward>
|
||||||
|
{
|
||||||
|
new QualityHediffReward(0.30f, 1, false, "ARA_QualityReward_1Hediff"),
|
||||||
|
new QualityHediffReward(0.50f, 2, false, "ARA_QualityReward_2Hediff"),
|
||||||
|
new QualityHediffReward(0.85f, 3, false, "ARA_QualityReward_3Hediff"),
|
||||||
|
new QualityHediffReward(0.99f, 4, true, "ARA_QualityReward_AllHediff")
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
// === 新增:配置后处理,确保每个配置都有Hediff奖励 ===
|
||||||
|
public override void PostLoadSpecial(ThingDef parent)
|
||||||
|
{
|
||||||
|
base.PostLoadSpecial(parent);
|
||||||
|
|
||||||
|
// 确保每个配置都有默认的奖励配置
|
||||||
|
foreach (var config in incubationConfigs)
|
||||||
|
{
|
||||||
|
if (config.hediffRewards == null || config.hediffRewards.Count == 0)
|
||||||
|
{
|
||||||
|
config.hediffRewards = new List<QualityHediffReward>
|
||||||
|
{
|
||||||
|
new QualityHediffReward(0.30f, 1, false, "ARA_QualityReward_1Hediff"),
|
||||||
|
new QualityHediffReward(0.50f, 2, false, "ARA_QualityReward_2Hediff"),
|
||||||
|
new QualityHediffReward(0.85f, 3, false, "ARA_QualityReward_3Hediff"),
|
||||||
|
new QualityHediffReward(0.99f, 4, true, "ARA_QualityReward_AllHediff")
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
// 合并全局Hediff列表
|
||||||
|
if (globalExtraHediffs != null && globalExtraHediffs.Count > 0)
|
||||||
|
{
|
||||||
|
if (config.extraHediffs == null)
|
||||||
|
config.extraHediffs = new List<HediffDef>();
|
||||||
|
|
||||||
|
foreach (var hediff in globalExtraHediffs)
|
||||||
|
{
|
||||||
|
if (!config.extraHediffs.Contains(hediff))
|
||||||
|
{
|
||||||
|
config.extraHediffs.Add(hediff);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 如果配置没有自己的奖励规则,使用全局规则
|
||||||
|
if (globalHediffRewards != null && globalHediffRewards.Count > 0)
|
||||||
|
{
|
||||||
|
if (config.hediffRewards == null || config.hediffRewards.Count == 0)
|
||||||
|
{
|
||||||
|
config.hediffRewards = new List<QualityHediffReward>(globalHediffRewards);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -174,5 +423,48 @@ namespace ArachnaeSwarm
|
|||||||
}
|
}
|
||||||
return base.CompInspectStringExtra();
|
return base.CompInspectStringExtra();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// === 新增:获取当前配置的Hediff奖励信息 ===
|
||||||
|
public string GetHediffRewardDescription()
|
||||||
|
{
|
||||||
|
var config = SelectedConfig;
|
||||||
|
if (config == null || config.extraHediffs == null || config.extraHediffs.Count == 0)
|
||||||
|
return null;
|
||||||
|
|
||||||
|
var builder = new StringBuilder();
|
||||||
|
builder.AppendLine("HediffRewards".Translate() + ":");
|
||||||
|
|
||||||
|
foreach (var hediff in config.extraHediffs)
|
||||||
|
{
|
||||||
|
if (hediff != null)
|
||||||
|
{
|
||||||
|
builder.AppendLine(" - " + hediff.LabelCap);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (config.hediffRewards != null && config.hediffRewards.Count > 0)
|
||||||
|
{
|
||||||
|
builder.AppendLine();
|
||||||
|
builder.AppendLine("QualityThresholds".Translate() + ":");
|
||||||
|
foreach (var reward in config.hediffRewards)
|
||||||
|
{
|
||||||
|
if (reward.qualityThreshold > 0 && reward.hediffCount > 0)
|
||||||
|
{
|
||||||
|
string rewardText = $" {reward.qualityThreshold:P0}: ";
|
||||||
|
if (reward.giveAllHediffs)
|
||||||
|
{
|
||||||
|
rewardText += "AllHediffsReward".Translate();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
rewardText += "HediffCountReward".Translate(reward.hediffCount);
|
||||||
|
}
|
||||||
|
builder.AppendLine(rewardText);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return builder.ToString().TrimEndNewlines();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -42,6 +42,25 @@ namespace ArachnaeSwarm
|
|||||||
// 获取其他卵距离检测半径的整数形式
|
// 获取其他卵距离检测半径的整数形式
|
||||||
public int NearbyOothecaRadiusInt => (int)nearbyOothecaRadius;
|
public int NearbyOothecaRadiusInt => (int)nearbyOothecaRadius;
|
||||||
|
|
||||||
|
// 是否启用营养液不足时的伤害
|
||||||
|
public bool nutrientDeficiencyDamageEnabled = false;
|
||||||
|
|
||||||
|
// 每次检查间隔造成的伤害量
|
||||||
|
public float nutrientDeficiencyDamageAmount = 1f;
|
||||||
|
|
||||||
|
// 伤害类型
|
||||||
|
public DamageDef nutrientDamageType = DamageDefOf.Burn;
|
||||||
|
|
||||||
|
// 是否显示伤害消息
|
||||||
|
public bool showDamageMessages = true;
|
||||||
|
|
||||||
|
// 伤害消息显示几率(避免刷屏)
|
||||||
|
public float damageMessageChance = 0.1f;
|
||||||
|
|
||||||
|
// 是否在营养液不足时停止孵化(如果设置为true,则缺少营养液时停止孵化进度)
|
||||||
|
public bool stopIncubationWhenNutrientDeficient = false;
|
||||||
|
|
||||||
|
|
||||||
public static OothecaIncubatorExtension Get(Thing thing)
|
public static OothecaIncubatorExtension Get(Thing thing)
|
||||||
{
|
{
|
||||||
if (thing?.def?.GetModExtension<OothecaIncubatorExtension>() is OothecaIncubatorExtension ext)
|
if (thing?.def?.GetModExtension<OothecaIncubatorExtension>() is OothecaIncubatorExtension ext)
|
||||||
@@ -57,8 +76,7 @@ namespace ArachnaeSwarm
|
|||||||
nutrientSolutionBonusPerTile >= 0f &&
|
nutrientSolutionBonusPerTile >= 0f &&
|
||||||
nearbyOothecaPenaltyPerUnit >= 0f;
|
nearbyOothecaPenaltyPerUnit >= 0f;
|
||||||
}
|
}
|
||||||
|
// 默认实例
|
||||||
// 获取默认扩展(用于兼容性)
|
public static readonly OothecaIncubatorExtension Default = new OothecaIncubatorExtension();
|
||||||
public static OothecaIncubatorExtension Default => new OothecaIncubatorExtension();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user