1
This commit is contained in:
Binary file not shown.
@@ -22,11 +22,14 @@
|
|||||||
<FleckDef ParentName="FleckBase">
|
<FleckDef ParentName="FleckBase">
|
||||||
<defName>WULA_GunTail_Lighting</defName>
|
<defName>WULA_GunTail_Lighting</defName>
|
||||||
<altitudeLayer>Projectile</altitudeLayer>
|
<altitudeLayer>Projectile</altitudeLayer>
|
||||||
<fadeOutTime>0.5</fadeOutTime>
|
<fadeInTime>0.50</fadeInTime>
|
||||||
|
<solidTime>1</solidTime>
|
||||||
|
<fadeOutTime>1.2</fadeOutTime>
|
||||||
|
<growthRate>0.005</growthRate>
|
||||||
<graphicData>
|
<graphicData>
|
||||||
<texPath>Wula/Mote/WULA_Lighting_Beam</texPath>
|
<texPath>Wula/Mote/WULA_Lighting_Beam</texPath>
|
||||||
<shaderType>MoteGlow</shaderType>
|
<shaderType>MoteGlow</shaderType>
|
||||||
<color>(113,165,225,155)</color>
|
<color>(113,165,225,255)</color>
|
||||||
<drawSize>(0.5,2)</drawSize>
|
<drawSize>(0.5,2)</drawSize>
|
||||||
</graphicData>
|
</graphicData>
|
||||||
</FleckDef>
|
</FleckDef>
|
||||||
|
|||||||
@@ -27,6 +27,13 @@
|
|||||||
<value>1</value>
|
<value>1</value>
|
||||||
<type>Int</type>
|
<type>Int</type>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
|
<!-- 设置私人好感 -->
|
||||||
|
<li Class="WulaFallenEmpire.Effect_SetVariable">
|
||||||
|
<name>Wula_Legion_Personal_Goodwill</name>
|
||||||
|
<value>0</value>
|
||||||
|
<type>Int</type>
|
||||||
|
</li>
|
||||||
</effects>
|
</effects>
|
||||||
</li>
|
</li>
|
||||||
</immediateEffects>
|
</immediateEffects>
|
||||||
@@ -41,6 +48,9 @@
|
|||||||
<optionEffects>
|
<optionEffects>
|
||||||
<li>
|
<li>
|
||||||
<effects>
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_10</defName>
|
||||||
|
</li>
|
||||||
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
</effects>
|
</effects>
|
||||||
</li>
|
</li>
|
||||||
@@ -68,6 +78,28 @@
|
|||||||
</li>
|
</li>
|
||||||
</optionEffects>
|
</optionEffects>
|
||||||
</li>
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>有什么任务吗···</label>
|
||||||
|
<!-- <disabledReason>殖民地的表现让P.I.A相当不满意,不会为殖民地派出任何额外增援</disabledReason>
|
||||||
|
<conditions>
|
||||||
|
<li Class="WulaFallenEmpire.Condition_VariableGreaterThan">
|
||||||
|
<name>Wula_Goodwill_To_PIA</name>
|
||||||
|
<value>-75</value>
|
||||||
|
</li>
|
||||||
|
</conditions> -->
|
||||||
|
<hideWhenDisabled>false</hideWhenDisabled>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_50</defName>
|
||||||
|
</li>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<label>我们想要接受晋级审查···</label>
|
<label>我们想要接受晋级审查···</label>
|
||||||
<hideWhenDisabled>true</hideWhenDisabled>
|
<hideWhenDisabled>true</hideWhenDisabled>
|
||||||
@@ -124,6 +156,218 @@
|
|||||||
</options>
|
</options>
|
||||||
</WulaFallenEmpire.EventDef>
|
</WulaFallenEmpire.EventDef>
|
||||||
|
|
||||||
|
<WulaFallenEmpire.EventDef>
|
||||||
|
<defName>Wula_UI_Legion_10</defName>
|
||||||
|
<label>未知通讯</label>
|
||||||
|
<portraitPath>Wula/Events/Portraits/WULA_Legion_5</portraitPath>
|
||||||
|
<characterName>「军团」,P.I.A</characterName>
|
||||||
|
<descriptions>
|
||||||
|
<li>嗯嗯?</li>
|
||||||
|
<li>好的——那么,你们要问什么?</li>
|
||||||
|
<li>哎,行吧,想问什么?</li>
|
||||||
|
</descriptions>
|
||||||
|
<options>
|
||||||
|
<li>
|
||||||
|
<label>你是谁?</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_11</defName>
|
||||||
|
</li>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>我们需要做什么?(发展流程)</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_14</defName>
|
||||||
|
</li>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>没有别的问题了······</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_1</defName>
|
||||||
|
</li>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
</options>
|
||||||
|
</WulaFallenEmpire.EventDef>
|
||||||
|
<WulaFallenEmpire.EventDef>
|
||||||
|
<defName>Wula_UI_Legion_11</defName>
|
||||||
|
<label>未知通讯</label>
|
||||||
|
<portraitPath>Wula/Events/Portraits/WULA_Legion_3</portraitPath>
|
||||||
|
<characterName>「军团」,P.I.A</characterName>
|
||||||
|
<descriptions>
|
||||||
|
<li>记忆体坏掉了?\n\n···好吧,你们可以叫我「军团」,我是负责管理乌拉帝国行星封锁机关舰队的AI,根据你们的编制来说,我是你们的顶头上司。在登陆地表前,机械行会没有给你们设置正确的记忆扇区吗?</li>
|
||||||
|
</descriptions>
|
||||||
|
<options>
|
||||||
|
<li>
|
||||||
|
<label>行星封锁机关?</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_12</defName>
|
||||||
|
</li>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>机械行会?</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_13</defName>
|
||||||
|
</li>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>我们没有相关问题了···</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_10</defName>
|
||||||
|
</li>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
</options>
|
||||||
|
</WulaFallenEmpire.EventDef>
|
||||||
|
<WulaFallenEmpire.EventDef>
|
||||||
|
<defName>Wula_UI_Legion_12</defName>
|
||||||
|
<label>未知通讯</label>
|
||||||
|
<portraitPath>Wula/Events/Portraits/WULA_Legion_3</portraitPath>
|
||||||
|
<characterName>「军团」,P.I.A</characterName>
|
||||||
|
<descriptions>
|
||||||
|
<li>行星封锁机关是隶属于乌拉帝国开发署的暴力机关,控制着开发署所有的舰队,负责在疆域开拓中的侵略性接触。\n\n通常来说,类似边缘世界这样的星球,我们会直接封锁轨道,轰炸所有现存聚居地然后再投放殖民者,不过看起来这个世界还有救,所以你们作为第一批先遣队投放到星球上,和其他异族接触试探一下,明白了吗?</li>
|
||||||
|
</descriptions>
|
||||||
|
<options>
|
||||||
|
<li>
|
||||||
|
<label>我们还有别的问题···</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_11</defName>
|
||||||
|
</li>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>我们没有相关问题了···</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_10</defName>
|
||||||
|
</li>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
</options>
|
||||||
|
</WulaFallenEmpire.EventDef>
|
||||||
|
<WulaFallenEmpire.EventDef>
|
||||||
|
<defName>Wula_UI_Legion_13</defName>
|
||||||
|
<label>未知通讯</label>
|
||||||
|
<portraitPath>Wula/Events/Portraits/WULA_Legion_3</portraitPath>
|
||||||
|
<characterName>「军团」,P.I.A</characterName>
|
||||||
|
<descriptions>
|
||||||
|
<li>乌拉帝国机械行会负责所有的合成人的生产、审查、投放和初始化,你们在部署到舰队上时,应该会有一个机械师帮你们设置好预载了记忆的扇区,但是很显然那家伙失职了,才让你们在这里拿着一堆你们早该知道的事情来烦我。</li>
|
||||||
|
</descriptions>
|
||||||
|
<options>
|
||||||
|
<li>
|
||||||
|
<label>我们还有别的问题···</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_11</defName>
|
||||||
|
</li>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>我们没有相关问题了···</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_10</defName>
|
||||||
|
</li>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
</options>
|
||||||
|
</WulaFallenEmpire.EventDef>
|
||||||
|
<WulaFallenEmpire.EventDef>
|
||||||
|
<defName>Wula_UI_Legion_14</defName>
|
||||||
|
<label>未知通讯</label>
|
||||||
|
<portraitPath>Wula/Events/Portraits/WULA_Legion_3</portraitPath>
|
||||||
|
<characterName>「军团」,P.I.A</characterName>
|
||||||
|
<descriptions>
|
||||||
|
<li>你们的意思是,你们连不知道要干什么就被丢下来了?\n\n哎,你们要做的就是施展你们的百般武艺活下来,建立一个根据地。根据帝国税收法,你们每个一段时间需要上交税款——作为帝国殖民地,舰队和机群将成为你们的后盾。\n\n如果你们觉得你们准备好了,可以申请权限进阶审查,我会部署一个带卫队的分体去你们的殖民地考察一段时间,然后根据评级决定是否给你们晋升。晋升后的殖民地会获得更多的许可,允许调用更加强大的武备和支援。</li>
|
||||||
|
</descriptions>
|
||||||
|
<options>
|
||||||
|
<li>
|
||||||
|
<label>我们没有相关问题了···</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_10</defName>
|
||||||
|
</li>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
</options>
|
||||||
|
</WulaFallenEmpire.EventDef>
|
||||||
|
|
||||||
<WulaFallenEmpire.EventDef>
|
<WulaFallenEmpire.EventDef>
|
||||||
<defName>Wula_UI_Legion_30</defName>
|
<defName>Wula_UI_Legion_30</defName>
|
||||||
<label>和P.I.A的通讯</label>
|
<label>和P.I.A的通讯</label>
|
||||||
@@ -828,6 +1072,102 @@
|
|||||||
</options>
|
</options>
|
||||||
</WulaFallenEmpire.EventDef>
|
</WulaFallenEmpire.EventDef>
|
||||||
|
|
||||||
|
<WulaFallenEmpire.EventDef>
|
||||||
|
<defName>Wula_UI_Legion_50</defName>
|
||||||
|
<label>和P.I.A的通讯</label>
|
||||||
|
<portraitPath>Wula/Events/Portraits/WULA_Legion_1</portraitPath>
|
||||||
|
<characterName>「军团」,P.I.A</characterName>
|
||||||
|
<descriptions>
|
||||||
|
</descriptions>
|
||||||
|
<conditionalDescriptions>
|
||||||
|
<li>
|
||||||
|
<conditions>
|
||||||
|
<li Class="WulaFallenEmpire.Condition_VariableLessThanOrEqual">
|
||||||
|
<name>Wula_Reinforcement_From_PIA_Level</name>
|
||||||
|
<value>2</value>
|
||||||
|
</li>
|
||||||
|
</conditions>
|
||||||
|
<text>好吧,我手上有一些活,怎么说呢,不太好走乌拉帝国的标准审查流程,我的断爪卫队也不适合去做这些事情,确实需要有人帮我处理。\n\n你们挑个感兴趣的类型吧,我会把任务的需求发给你们。</text>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<conditions>
|
||||||
|
<li Class="WulaFallenEmpire.Condition_VariableEquals">
|
||||||
|
<name>Wula_Reinforcement_From_PIA_Level</name>
|
||||||
|
<value>3</value>
|
||||||
|
</li>
|
||||||
|
</conditions>
|
||||||
|
<text>你们应该已经遇到了那些帝国的叛徒了?我们已经陆陆续续地发现了她们在这个星球活动的迹象,你们的任务很难避开她们,要做好打硬仗的准备。\n\n你们挑个感兴趣的类型吧,我会把任务的需求发给你们。</text>
|
||||||
|
</li>
|
||||||
|
</conditionalDescriptions>
|
||||||
|
<immediateEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</immediateEffects>
|
||||||
|
<options>
|
||||||
|
<li>
|
||||||
|
<label>我们希望接受远征任务</label>
|
||||||
|
<!-- <useCustomColors>false</useCustomColors>
|
||||||
|
<normalColor>(130,49,47,255)</normalColor>
|
||||||
|
<hoverColor>(157,201,185,195)</hoverColor>
|
||||||
|
<textColor>(171,87,85,255)</textColor>
|
||||||
|
<textHoverColor>(255,255,255,255)</textHoverColor> -->
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>我们希望接受防守任务</label>
|
||||||
|
<!-- <useCustomColors>false</useCustomColors>
|
||||||
|
<normalColor>(130,49,47,255)</normalColor>
|
||||||
|
<hoverColor>(157,201,185,195)</hoverColor>
|
||||||
|
<textColor>(171,87,85,255)</textColor>
|
||||||
|
<textHoverColor>(255,255,255,255)</textHoverColor> -->
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>有没有什么特殊的任务···</label>
|
||||||
|
<!-- <useCustomColors>false</useCustomColors>
|
||||||
|
<normalColor>(130,49,47,255)</normalColor>
|
||||||
|
<hoverColor>(157,201,185,195)</hoverColor>
|
||||||
|
<textColor>(171,87,85,255)</textColor>
|
||||||
|
<textHoverColor>(255,255,255,255)</textHoverColor> -->
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>现在不太合适···</label>
|
||||||
|
<useCustomColors>false</useCustomColors>
|
||||||
|
<optionEffects>
|
||||||
|
<li>
|
||||||
|
<effects>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_OpenCustomUI">
|
||||||
|
<defName>Wula_UI_Legion_1</defName>
|
||||||
|
</li>
|
||||||
|
<li Class="WulaFallenEmpire.Effect_CloseDialog" />
|
||||||
|
</effects>
|
||||||
|
</li>
|
||||||
|
</optionEffects>
|
||||||
|
</li>
|
||||||
|
</options>
|
||||||
|
</WulaFallenEmpire.EventDef>
|
||||||
|
|
||||||
<!-- 乱丢垃圾 -->
|
<!-- 乱丢垃圾 -->
|
||||||
<WulaFallenEmpire.EventDef>
|
<WulaFallenEmpire.EventDef>
|
||||||
<defName>Wula_UI_Legion_Reply_1</defName>
|
<defName>Wula_UI_Legion_Reply_1</defName>
|
||||||
|
|||||||
@@ -1,40 +1,30 @@
|
|||||||
<?xml version="1.0" encoding="utf-8" ?>
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
<Defs>
|
<Defs>
|
||||||
<QuestScriptDef>
|
<QuestScriptDef>
|
||||||
<defName>OpportunitySite_BanditCamp</defName>
|
<defName>WULA_P_Mission_Attack_Camp</defName>
|
||||||
<rootSelectionWeight>1.0</rootSelectionWeight>
|
<rootSelectionWeight>0</rootSelectionWeight>
|
||||||
<rootMinPoints>350</rootMinPoints>
|
<autoAccept>false</autoAccept>
|
||||||
<canGiveRoyalFavor>true</canGiveRoyalFavor>
|
<sendAvailableLetter>true</sendAvailableLetter>
|
||||||
<expireDaysRange>4~8</expireDaysRange>
|
<defaultChallengeRating>3</defaultChallengeRating> <!-- 挑战等级(星级) -->
|
||||||
<successHistoryEvent MayRequire="Ludeon.RimWorld.Ideology">Raided_BanditCamp</successHistoryEvent>
|
<isRootSpecial>true</isRootSpecial> <!-- 特殊任务 -->
|
||||||
<everAcceptableInSpace>true</everAcceptableInSpace>
|
<defaultCharity>false</defaultCharity> <!-- 是否仁善 -->
|
||||||
|
<!-- 命名规则 -->
|
||||||
<questNameRules>
|
<questNameRules>
|
||||||
<rulesStrings>
|
<rulesStrings>
|
||||||
<li>questName->The [bandit] [camp]</li>
|
<li>questName->WULA_P_Mission_Attack_Camp_questName</li>
|
||||||
<li>questName->[bandit] [camp]</li>
|
|
||||||
<li>questName->[asker_nameDef] and the [camp]</li>
|
|
||||||
<li>camp->Camp</li>
|
|
||||||
<li>camp->Outpost</li>
|
|
||||||
<li>camp->Lair</li>
|
|
||||||
<li>camp->Encampment</li>
|
|
||||||
<li>bandit->Bandit</li>
|
|
||||||
<li>bandit->Raider</li>
|
|
||||||
<li>bandit->Outlaw</li>
|
|
||||||
<li>bandit->Desperado</li>
|
|
||||||
<li>bandit->Fugitive</li>
|
|
||||||
<li>bandit->Marauder</li>
|
|
||||||
<li>bandit->Robber</li>
|
|
||||||
<li>bandit->Brigand</li>
|
|
||||||
</rulesStrings>
|
</rulesStrings>
|
||||||
</questNameRules>
|
</questNameRules>
|
||||||
<questDescriptionRules>
|
<questDescriptionRules>
|
||||||
|
<include>
|
||||||
|
<li>QuestHospitalityCommon</li>
|
||||||
|
</include>
|
||||||
<rulesStrings>
|
<rulesStrings>
|
||||||
<li>questDescription->[asker_nameFull], [asker_faction_leaderTitle] of [asker_faction_name], has sent us a message. Apparently, [siteFaction_pawnsPlural] based in a nearby camp have been raiding their caravans. The camp is controlled by [siteFaction_name].
|
<li>questDescription->WULA_P_Mission_Attack_Camp_questDescription</li>
|
||||||
\n[asker_nameDef] is asking us to destroy the camp, which means eliminating all enemies and turrets. [asker_label] says that [sitePart0_description].</li>
|
|
||||||
</rulesStrings>
|
</rulesStrings>
|
||||||
</questDescriptionRules>
|
</questDescriptionRules>
|
||||||
<root Class="QuestNode_Sequence">
|
<root Class="QuestNode_Sequence">
|
||||||
<nodes>
|
<nodes>
|
||||||
|
<!-- 挑战数据 -->
|
||||||
<li Class="QuestNode_SubScript">
|
<li Class="QuestNode_SubScript">
|
||||||
<def>Util_RandomizePointsChallengeRating</def>
|
<def>Util_RandomizePointsChallengeRating</def>
|
||||||
<parms>
|
<parms>
|
||||||
@@ -51,13 +41,6 @@
|
|||||||
<canBeSpace>true</canBeSpace>
|
<canBeSpace>true</canBeSpace>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li Class="QuestNode_GetPawn">
|
|
||||||
<storeAs>asker</storeAs>
|
|
||||||
<mustBeFactionLeader>true</mustBeFactionLeader>
|
|
||||||
<allowPermanentEnemyFaction>false</allowPermanentEnemyFaction>
|
|
||||||
<hostileWeight>0.15</hostileWeight>
|
|
||||||
</li>
|
|
||||||
|
|
||||||
<li Class="QuestNode_GetSiteTile">
|
<li Class="QuestNode_GetSiteTile">
|
||||||
<storeAs>siteTile</storeAs>
|
<storeAs>siteTile</storeAs>
|
||||||
<preferCloserTiles>true</preferCloserTiles>
|
<preferCloserTiles>true</preferCloserTiles>
|
||||||
@@ -4,6 +4,6 @@
|
|||||||
<defName>WULA_ResearchTab</defName>
|
<defName>WULA_ResearchTab</defName>
|
||||||
<label>乌拉帝国科技</label>
|
<label>乌拉帝国科技</label>
|
||||||
<generalTitle>乌拉帝国科技项目</generalTitle>
|
<generalTitle>乌拉帝国科技项目</generalTitle>
|
||||||
<generalDescription>解锁和乌拉帝国相关的研究项目,破解强大的堕落帝国科技产物和机械体。</generalDescription>
|
<generalDescription>解锁和乌拉帝国相关的研究项目,申请强大的堕落帝国科技产物、舰队和战争机械。</generalDescription>
|
||||||
</ResearchTabDef>
|
</ResearchTabDef>
|
||||||
</Defs>
|
</Defs>
|
||||||
|
|||||||
@@ -776,7 +776,16 @@
|
|||||||
<ThingDef ParentName="BaseBullet">
|
<ThingDef ParentName="BaseBullet">
|
||||||
<defName>Bullet_WULA_WM_Panzer_Turret</defName>
|
<defName>Bullet_WULA_WM_Panzer_Turret</defName>
|
||||||
<label>金红石穿甲弹</label>
|
<label>金红石穿甲弹</label>
|
||||||
<thingClass>WulaFallenEmpire.Projectile_ExplosiveWithTrail</thingClass>
|
<thingClass>WulaFallenEmpire.Projectile_WulaLineAttack</thingClass>
|
||||||
|
<modExtensions>
|
||||||
|
<li Class="WulaFallenEmpire.Wula_PathPierce_Extension">
|
||||||
|
<maxHits>-1</maxHits> <!-- 无限穿透 -->
|
||||||
|
<damageFalloff>0</damageFalloff> <!-- 无伤害衰减 -->
|
||||||
|
<preventFriendlyFire>true</preventFriendlyFire> <!-- 是否阻止友方火力 -->
|
||||||
|
<tailFleckDef>WULA_GunTail_Lighting</tailFleckDef> <!-- 拖尾特效定义 -->
|
||||||
|
<hitEffecterDef>Bullet_WULA_WM_Panzer_Turret_Hit</hitEffecterDef>
|
||||||
|
</li>
|
||||||
|
</modExtensions>
|
||||||
<tickerType>Normal</tickerType>
|
<tickerType>Normal</tickerType>
|
||||||
<neverMultiSelect>True</neverMultiSelect>
|
<neverMultiSelect>True</neverMultiSelect>
|
||||||
<graphicData>
|
<graphicData>
|
||||||
@@ -806,6 +815,54 @@
|
|||||||
</li>
|
</li>
|
||||||
</modExtensions>
|
</modExtensions>
|
||||||
</ThingDef>
|
</ThingDef>
|
||||||
|
<EffecterDef>
|
||||||
|
<defName>Bullet_WULA_WM_Panzer_Turret_Hit</defName>
|
||||||
|
<children>
|
||||||
|
<li>
|
||||||
|
<subEffecterClass>SubEffecter_SprayerTriggered</subEffecterClass>
|
||||||
|
<positionRadius>0.1</positionRadius>
|
||||||
|
<moteDef>WULA_Mote_halo</moteDef>
|
||||||
|
<burstCount>1~1</burstCount>
|
||||||
|
<speed>0.4~0.8</speed>
|
||||||
|
<scale>0.05~0.05</scale>
|
||||||
|
<spawnLocType>OnSource</spawnLocType>
|
||||||
|
<color>(255,255,255)</color>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<subEffecterClass>SubEffecter_SprayerTriggered</subEffecterClass>
|
||||||
|
<positionRadius>0.02</positionRadius>
|
||||||
|
<moteDef>WULA_Mote_halo</moteDef>
|
||||||
|
<burstCount>1~1</burstCount>
|
||||||
|
<speed>0.3~0.4</speed>
|
||||||
|
<rotationRate>5~10</rotationRate>
|
||||||
|
<scale>0.1~0.2</scale>
|
||||||
|
<spawnLocType>OnSource</spawnLocType>
|
||||||
|
<color>(255,255,255)</color>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<subEffecterClass>SubEffecter_SprayerTriggered</subEffecterClass>
|
||||||
|
<moteDef>WULA_Mote_ChargeLanceShot</moteDef>
|
||||||
|
<burstCount>6~12</burstCount>
|
||||||
|
<scale>0.4~0.8</scale>
|
||||||
|
<speed>20~40</speed>
|
||||||
|
<angle>135~225</angle>
|
||||||
|
<positionRadius>0.01</positionRadius>
|
||||||
|
<spawnLocType>OnSource</spawnLocType>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<subEffecterClass>SubEffecter_SprayerTriggered</subEffecterClass>
|
||||||
|
<moteDef>WULA_Mote_ChargeLanceShot</moteDef>
|
||||||
|
<burstCount>5~9</burstCount>
|
||||||
|
<scale>0.4~0.8</scale>
|
||||||
|
<speed>10~20</speed>
|
||||||
|
<angle>135~225</angle>
|
||||||
|
<positionRadius>0.01</positionRadius>
|
||||||
|
<spawnLocType>OnSource</spawnLocType>
|
||||||
|
</li>
|
||||||
|
</children>
|
||||||
|
<offsetTowardsTarget>0.25~0.25</offsetTowardsTarget>
|
||||||
|
<positionRadius>0.1</positionRadius>
|
||||||
|
</EffecterDef>
|
||||||
|
|
||||||
<!-- 激光炮 -->
|
<!-- 激光炮 -->
|
||||||
<ThingDef ParentName="BuildingBase">
|
<ThingDef ParentName="BuildingBase">
|
||||||
|
|||||||
@@ -818,7 +818,7 @@
|
|||||||
<AccuracyShort>0.7</AccuracyShort>
|
<AccuracyShort>0.7</AccuracyShort>
|
||||||
<AccuracyMedium>1</AccuracyMedium>
|
<AccuracyMedium>1</AccuracyMedium>
|
||||||
<AccuracyLong>1</AccuracyLong>
|
<AccuracyLong>1</AccuracyLong>
|
||||||
<RangedWeapon_Cooldown>0.5</RangedWeapon_Cooldown>
|
<RangedWeapon_Cooldown>1.5</RangedWeapon_Cooldown>
|
||||||
</statBases>
|
</statBases>
|
||||||
<costList Inherit="False">
|
<costList Inherit="False">
|
||||||
<WULA_Alloy>60</WULA_Alloy>
|
<WULA_Alloy>60</WULA_Alloy>
|
||||||
@@ -826,7 +826,7 @@
|
|||||||
</costList>
|
</costList>
|
||||||
<verbs>
|
<verbs>
|
||||||
<li>
|
<li>
|
||||||
<verbClass>WulaFallenEmpire.Verb_ShootWithOffset</verbClass>
|
<verbClass>WulaFallenEmpire.Verb_ShootBeyondTarge</verbClass>
|
||||||
<hasStandardCommand>true</hasStandardCommand>
|
<hasStandardCommand>true</hasStandardCommand>
|
||||||
<defaultProjectile>Bullet_WULA_RW_Fractal_RF</defaultProjectile>
|
<defaultProjectile>Bullet_WULA_RW_Fractal_RF</defaultProjectile>
|
||||||
<warmupTime>1.25</warmupTime>
|
<warmupTime>1.25</warmupTime>
|
||||||
@@ -865,6 +865,7 @@
|
|||||||
<damageFalloff>0</damageFalloff> <!-- 无伤害衰减 -->
|
<damageFalloff>0</damageFalloff> <!-- 无伤害衰减 -->
|
||||||
<preventFriendlyFire>true</preventFriendlyFire> <!-- 是否阻止友方火力 -->
|
<preventFriendlyFire>true</preventFriendlyFire> <!-- 是否阻止友方火力 -->
|
||||||
<tailFleckDef>WULA_GunTail_Lighting</tailFleckDef> <!-- 拖尾特效定义 -->
|
<tailFleckDef>WULA_GunTail_Lighting</tailFleckDef> <!-- 拖尾特效定义 -->
|
||||||
|
<!-- <hitEffecterDef>Bullet_WULA_RW_Fractal_RF_Hit</hitEffecterDef> -->
|
||||||
</li>
|
</li>
|
||||||
</modExtensions>
|
</modExtensions>
|
||||||
<graphicData>
|
<graphicData>
|
||||||
@@ -881,6 +882,54 @@
|
|||||||
<stoppingPower>5</stoppingPower>
|
<stoppingPower>5</stoppingPower>
|
||||||
</projectile>
|
</projectile>
|
||||||
</ThingDef>
|
</ThingDef>
|
||||||
|
<EffecterDef>
|
||||||
|
<defName>Bullet_WULA_RW_Fractal_RF_Hit</defName>
|
||||||
|
<children>
|
||||||
|
<li>
|
||||||
|
<subEffecterClass>SubEffecter_SprayerTriggered</subEffecterClass>
|
||||||
|
<positionRadius>0.1</positionRadius>
|
||||||
|
<moteDef>WULA_Mote_halo</moteDef>
|
||||||
|
<burstCount>1~1</burstCount>
|
||||||
|
<speed>0.4~0.8</speed>
|
||||||
|
<scale>0.05~0.05</scale>
|
||||||
|
<spawnLocType>OnSource</spawnLocType>
|
||||||
|
<color>(255,255,255)</color>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<subEffecterClass>SubEffecter_SprayerTriggered</subEffecterClass>
|
||||||
|
<positionRadius>0.02</positionRadius>
|
||||||
|
<moteDef>WULA_Mote_halo</moteDef>
|
||||||
|
<burstCount>1~1</burstCount>
|
||||||
|
<speed>0.3~0.4</speed>
|
||||||
|
<rotationRate>5~10</rotationRate>
|
||||||
|
<scale>0.1~0.2</scale>
|
||||||
|
<spawnLocType>OnSource</spawnLocType>
|
||||||
|
<color>(255,255,255)</color>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<subEffecterClass>SubEffecter_SprayerTriggered</subEffecterClass>
|
||||||
|
<moteDef>WULA_Mote_ChargeLanceShot</moteDef>
|
||||||
|
<burstCount>6~12</burstCount>
|
||||||
|
<scale>0.4~0.8</scale>
|
||||||
|
<speed>20~40</speed>
|
||||||
|
<angle>135~225</angle>
|
||||||
|
<positionRadius>0.01</positionRadius>
|
||||||
|
<spawnLocType>OnSource</spawnLocType>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<subEffecterClass>SubEffecter_SprayerTriggered</subEffecterClass>
|
||||||
|
<moteDef>WULA_Mote_ChargeLanceShot</moteDef>
|
||||||
|
<burstCount>5~9</burstCount>
|
||||||
|
<scale>0.4~0.8</scale>
|
||||||
|
<speed>10~20</speed>
|
||||||
|
<angle>135~225</angle>
|
||||||
|
<positionRadius>0.01</positionRadius>
|
||||||
|
<spawnLocType>OnSource</spawnLocType>
|
||||||
|
</li>
|
||||||
|
</children>
|
||||||
|
<offsetTowardsTarget>0.25~0.25</offsetTowardsTarget>
|
||||||
|
<positionRadius>0.1</positionRadius>
|
||||||
|
</EffecterDef>
|
||||||
<ThingDef ParentName="WULA_ExperienceCore_Weapon_Ranged">
|
<ThingDef ParentName="WULA_ExperienceCore_Weapon_Ranged">
|
||||||
<defName>WULA_RW_StarDrift_SG</defName>
|
<defName>WULA_RW_StarDrift_SG</defName>
|
||||||
<label>DCs-7"黑曜石"</label>
|
<label>DCs-7"黑曜石"</label>
|
||||||
|
|||||||
147
Source/WulaFallenEmpire/Damage/202512031732.xml
Normal file
147
Source/WulaFallenEmpire/Damage/202512031732.xml
Normal file
@@ -0,0 +1,147 @@
|
|||||||
|
<!-- 1. 基本额外伤害配置 -->
|
||||||
|
<DamageDef>
|
||||||
|
<defName>Damage_WithExtraEffects</defName>
|
||||||
|
<label>带电击伤害</label>
|
||||||
|
<workerClass>WulaFallenEmpire.DamageWorker_ExtraDamage</workerClass>
|
||||||
|
|
||||||
|
<modExtensions>
|
||||||
|
<li Class="WulaFallenEmpire.DamageDef_ExtraDamageExtension">
|
||||||
|
<extraLabel>电击效果</extraLabel>
|
||||||
|
<showExtraLog>true</showExtraLog>
|
||||||
|
|
||||||
|
<extraDamages>
|
||||||
|
<li>
|
||||||
|
<damageDef>EMP</damageDef>
|
||||||
|
<amount>15</amount>
|
||||||
|
<isPercentage>false</isPercentage>
|
||||||
|
<armorPenetration>25</armorPenetration>
|
||||||
|
<soundDef>EMP_Small</soundDef>
|
||||||
|
<fleckDef>ElectricArc</fleckDef>
|
||||||
|
<minTriggerDamage>5</minTriggerDamage>
|
||||||
|
|
||||||
|
<conditions>
|
||||||
|
<li>
|
||||||
|
<targetType>Mechanoid</targetType>
|
||||||
|
<healthPercentRange>0,1</healthPercentRange>
|
||||||
|
</li>
|
||||||
|
</conditions>
|
||||||
|
</li>
|
||||||
|
</extraDamages>
|
||||||
|
</li>
|
||||||
|
</modExtensions>
|
||||||
|
</DamageDef>
|
||||||
|
|
||||||
|
<!-- 2. 百分比额外伤害 -->
|
||||||
|
<DamageDef>
|
||||||
|
<defName>Damage_WithBurn</defName>
|
||||||
|
<label>带燃烧伤害</label>
|
||||||
|
<workerClass>WulaFallenEmpire.DamageWorker_ExtraDamage</workerClass>
|
||||||
|
|
||||||
|
<modExtensions>
|
||||||
|
<li Class="WulaFallenEmpire.DamageDef_ExtraDamageExtension">
|
||||||
|
<extraLabel>燃烧效果</extraLabel>
|
||||||
|
|
||||||
|
<extraDamages>
|
||||||
|
<li>
|
||||||
|
<damageDef>Burn</damageDef>
|
||||||
|
<isPercentage>true</isPercentage>
|
||||||
|
<percentageMultiplier>0.3</percentageMultiplier>
|
||||||
|
<effecterDef>SparkHit</effecterDef>
|
||||||
|
<minTriggerDamage>10</minTriggerDamage>
|
||||||
|
|
||||||
|
<conditions>
|
||||||
|
<li>
|
||||||
|
<targetType>Pawn</targetType>
|
||||||
|
<healthPercentRange>0.3,1</healthPercentRange>
|
||||||
|
<requiredTags>
|
||||||
|
<li>Flammable</li>
|
||||||
|
</requiredTags>
|
||||||
|
</li>
|
||||||
|
</conditions>
|
||||||
|
</li>
|
||||||
|
</extraDamages>
|
||||||
|
</li>
|
||||||
|
</modExtensions>
|
||||||
|
</DamageDef>
|
||||||
|
|
||||||
|
<!-- 3. 多种额外伤害 -->
|
||||||
|
<DamageDef>
|
||||||
|
<defName>Damage_MultiEffect</defName>
|
||||||
|
<label>多重效果伤害</label>
|
||||||
|
<workerClass>WulaFallenEmpire.DamageWorker_ExtraDamage</workerClass>
|
||||||
|
|
||||||
|
<modExtensions>
|
||||||
|
<li Class="WulaFallenEmpire.DamageDef_ExtraDamageExtension">
|
||||||
|
<extraLabel>组合效果</extraLabel>
|
||||||
|
|
||||||
|
<extraDamages>
|
||||||
|
<!-- 对生物造成流血 -->
|
||||||
|
<li>
|
||||||
|
<damageDef>Cut</damageDef>
|
||||||
|
<amount>5</amount>
|
||||||
|
<isPercentage>false</isPercentage>
|
||||||
|
<targetBodyPart>Torso</targetBodyPart>
|
||||||
|
|
||||||
|
<conditions>
|
||||||
|
<li>
|
||||||
|
<targetType>Animal</targetType>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<targetType>Humanlike</targetType>
|
||||||
|
</li>
|
||||||
|
</conditions>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<!-- 对机械造成EMP -->
|
||||||
|
<li>
|
||||||
|
<damageDef>EMP</damageDef>
|
||||||
|
<isPercentage>true</isPercentage>
|
||||||
|
<percentageMultiplier>0.5</percentageMultiplier>
|
||||||
|
<canBeBlockedByArmor>false</canBeBlockedByArmor>
|
||||||
|
|
||||||
|
<conditions>
|
||||||
|
<li>
|
||||||
|
<targetType>Mechanoid</targetType>
|
||||||
|
</li>
|
||||||
|
</conditions>
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<!-- 对建筑造成额外伤害 -->
|
||||||
|
<li>
|
||||||
|
<damageDef>Blunt</damageDef>
|
||||||
|
<amount>20</amount>
|
||||||
|
<isPercentage>false</isPercentage>
|
||||||
|
|
||||||
|
<conditions>
|
||||||
|
<li>
|
||||||
|
<targetType>Building</targetType>
|
||||||
|
</li>
|
||||||
|
</conditions>
|
||||||
|
</li>
|
||||||
|
</extraDamages>
|
||||||
|
</li>
|
||||||
|
</modExtensions>
|
||||||
|
</DamageDef>
|
||||||
|
|
||||||
|
<!-- 4. 武器使用这个伤害类型 -->
|
||||||
|
<ThingDef>
|
||||||
|
<defName>Gun_AdvancedRifle</defName>
|
||||||
|
<label>先进步枪</label>
|
||||||
|
|
||||||
|
<verbs>
|
||||||
|
<li>
|
||||||
|
<verbClass>Verb_Shoot</verbClass>
|
||||||
|
<defaultProjectile>Bullet_Advanced</defaultProjectile>
|
||||||
|
</li>
|
||||||
|
</verbs>
|
||||||
|
</ThingDef>
|
||||||
|
|
||||||
|
<!-- 5. 抛射体定义 -->
|
||||||
|
<ThingDef>
|
||||||
|
<defName>Bullet_Advanced</defName>
|
||||||
|
<label>先进子弹</label>
|
||||||
|
<projectile>
|
||||||
|
<damageDef>Damage_MultiEffect</damageDef>
|
||||||
|
<damageAmountBase>25</damageAmountBase>
|
||||||
|
</projectile>
|
||||||
|
</ThingDef>
|
||||||
299
Source/WulaFallenEmpire/Damage/DamageDef_ExtraDamageExtension.cs
Normal file
299
Source/WulaFallenEmpire/Damage/DamageDef_ExtraDamageExtension.cs
Normal file
@@ -0,0 +1,299 @@
|
|||||||
|
using System.Collections.Generic;
|
||||||
|
using Verse;
|
||||||
|
using RimWorld;
|
||||||
|
|
||||||
|
namespace WulaFallenEmpire
|
||||||
|
{
|
||||||
|
public class DamageDef_ExtraDamageExtension : DefModExtension
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 额外伤害列表
|
||||||
|
/// </summary>
|
||||||
|
public List<ExtraDamageDef> extraDamages = new List<ExtraDamageDef>();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 条件触发器列表
|
||||||
|
/// </summary>
|
||||||
|
public List<DamageCondition> conditions = new List<DamageCondition>();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 是否显示额外的战斗日志信息
|
||||||
|
/// </summary>
|
||||||
|
public bool showExtraLog = true;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 额外伤害标签
|
||||||
|
/// </summary>
|
||||||
|
public string extraLabel = "";
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取所有适用于特定目标的额外伤害
|
||||||
|
/// </summary>
|
||||||
|
public List<ExtraDamageDef> GetApplicableExtraDamages(Thing target, DamageInfo originalDinfo)
|
||||||
|
{
|
||||||
|
List<ExtraDamageDef> result = new List<ExtraDamageDef>();
|
||||||
|
|
||||||
|
foreach (var extraDamage in extraDamages)
|
||||||
|
{
|
||||||
|
if (IsConditionMet(extraDamage.conditions, target, originalDinfo))
|
||||||
|
{
|
||||||
|
result.Add(extraDamage);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 检查条件是否满足
|
||||||
|
/// </summary>
|
||||||
|
private bool IsConditionMet(List<DamageCondition> conditions, Thing target, DamageInfo originalDinfo)
|
||||||
|
{
|
||||||
|
if (conditions == null || conditions.Count == 0)
|
||||||
|
return true;
|
||||||
|
|
||||||
|
foreach (var condition in conditions)
|
||||||
|
{
|
||||||
|
if (!condition.IsMet(target, originalDinfo))
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 额外伤害定义
|
||||||
|
/// </summary>
|
||||||
|
public class ExtraDamageDef
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 伤害类型
|
||||||
|
/// </summary>
|
||||||
|
public DamageDef damageDef;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 伤害数值(如果是百分比,基于原始伤害)
|
||||||
|
/// </summary>
|
||||||
|
public float amount = 10f;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 是否为百分比伤害(相对于原始伤害)
|
||||||
|
/// </summary>
|
||||||
|
public bool isPercentage = false;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 百分比倍数(当isPercentage为true时有效)
|
||||||
|
/// </summary>
|
||||||
|
public float percentageMultiplier = 0.5f;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 护甲穿透值
|
||||||
|
/// </summary>
|
||||||
|
public float armorPenetration = -1f; // -1表示使用damageDef的默认值
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 命中部位(可选)
|
||||||
|
/// </summary>
|
||||||
|
public BodyPartDef targetBodyPart;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 伤害应用条件
|
||||||
|
/// </summary>
|
||||||
|
public List<DamageCondition> conditions = new List<DamageCondition>();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 伤害应用后的效果器
|
||||||
|
/// </summary>
|
||||||
|
public EffecterDef effecterDef;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 伤害应用后的粒子
|
||||||
|
/// </summary>
|
||||||
|
public FleckDef fleckDef;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 伤害应用后的音效
|
||||||
|
/// </summary>
|
||||||
|
public SoundDef soundDef;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 最小触发伤害阈值
|
||||||
|
/// </summary>
|
||||||
|
public float minTriggerDamage = 0f;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 是否可以被护甲抵抗
|
||||||
|
/// </summary>
|
||||||
|
public bool canBeBlockedByArmor = true;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 是否为真实伤害(忽略所有抗性)
|
||||||
|
/// </summary>
|
||||||
|
public bool isTrueDamage = false;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 计算实际伤害值
|
||||||
|
/// </summary>
|
||||||
|
public float CalculateActualAmount(DamageInfo originalDinfo, Thing target)
|
||||||
|
{
|
||||||
|
if (isPercentage)
|
||||||
|
{
|
||||||
|
return originalDinfo.Amount * percentageMultiplier;
|
||||||
|
}
|
||||||
|
return amount;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 计算实际护甲穿透值
|
||||||
|
/// </summary>
|
||||||
|
public float CalculateActualArmorPenetration()
|
||||||
|
{
|
||||||
|
if (armorPenetration >= 0)
|
||||||
|
return armorPenetration;
|
||||||
|
return damageDef.defaultArmorPenetration;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 伤害条件
|
||||||
|
/// </summary>
|
||||||
|
public class DamageCondition
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 目标类型
|
||||||
|
/// </summary>
|
||||||
|
public ConditionTarget targetType = ConditionTarget.Any;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 特定种族列表(当targetType为SpecificRaces时有效)
|
||||||
|
/// </summary>
|
||||||
|
public List<ThingDef> specificRaces = new List<ThingDef>();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 目标血量百分比阈值
|
||||||
|
/// </summary>
|
||||||
|
public FloatRange healthPercentRange = new FloatRange(0f, 1f);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 目标是否必须存活
|
||||||
|
/// </summary>
|
||||||
|
public bool targetMustBeAlive = true;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 目标是否必须有特定标签
|
||||||
|
/// </summary>
|
||||||
|
public List<string> requiredTags = new List<string>();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 原始伤害类型限制
|
||||||
|
/// </summary>
|
||||||
|
public List<DamageDef> requiredOriginalDamageTypes = new List<DamageDef>();
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 原始伤害必须大于
|
||||||
|
/// </summary>
|
||||||
|
public float originalDamageMustBeGreaterThan = 0f;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 检查条件是否满足
|
||||||
|
/// </summary>
|
||||||
|
public bool IsMet(Thing target, DamageInfo originalDinfo)
|
||||||
|
{
|
||||||
|
// 检查目标类型
|
||||||
|
if (!CheckTargetType(target))
|
||||||
|
return false;
|
||||||
|
|
||||||
|
// 检查血量百分比
|
||||||
|
if (!CheckHealthPercentage(target))
|
||||||
|
return false;
|
||||||
|
|
||||||
|
// 检查存活状态
|
||||||
|
if (targetMustBeAlive && target is Pawn pawn && (pawn.Dead || pawn.Downed))
|
||||||
|
return false;
|
||||||
|
|
||||||
|
// 检查标签
|
||||||
|
if (!CheckTags(target))
|
||||||
|
return false;
|
||||||
|
|
||||||
|
// 检查原始伤害类型
|
||||||
|
if (!CheckOriginalDamageType(originalDinfo))
|
||||||
|
return false;
|
||||||
|
|
||||||
|
// 检查原始伤害大小
|
||||||
|
if (originalDinfo.Amount <= originalDamageMustBeGreaterThan)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
private bool CheckTargetType(Thing target)
|
||||||
|
{
|
||||||
|
switch (targetType)
|
||||||
|
{
|
||||||
|
case ConditionTarget.Any:
|
||||||
|
return true;
|
||||||
|
case ConditionTarget.Pawn:
|
||||||
|
return target is Pawn;
|
||||||
|
case ConditionTarget.Animal:
|
||||||
|
return target is Pawn pawn && pawn.RaceProps.Animal;
|
||||||
|
case ConditionTarget.Humanlike:
|
||||||
|
return target is Pawn pawn && pawn.RaceProps.Humanlike;
|
||||||
|
case ConditionTarget.Mechanoid:
|
||||||
|
return target is Pawn pawn && pawn.RaceProps.IsMechanoid;
|
||||||
|
case ConditionTarget.Building:
|
||||||
|
return target is Building;
|
||||||
|
case ConditionTarget.SpecificRaces:
|
||||||
|
return target is Pawn pawn && specificRaces.Contains(pawn.def);
|
||||||
|
default:
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private bool CheckHealthPercentage(Thing target)
|
||||||
|
{
|
||||||
|
if (target is Pawn pawn)
|
||||||
|
{
|
||||||
|
float healthPercent = pawn.health.summaryHealth.SummaryHealthPercent;
|
||||||
|
return healthPercentRange.Includes(healthPercent);
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
private bool CheckTags(Thing target)
|
||||||
|
{
|
||||||
|
if (requiredTags == null || requiredTags.Count == 0)
|
||||||
|
return true;
|
||||||
|
|
||||||
|
foreach (var tag in requiredTags)
|
||||||
|
{
|
||||||
|
if (target.def.HasTag(tag))
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private bool CheckOriginalDamageType(DamageInfo originalDinfo)
|
||||||
|
{
|
||||||
|
if (requiredOriginalDamageTypes == null || requiredOriginalDamageTypes.Count == 0)
|
||||||
|
return true;
|
||||||
|
|
||||||
|
return requiredOriginalDamageTypes.Contains(originalDinfo.Def);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 条件目标类型
|
||||||
|
/// </summary>
|
||||||
|
public enum ConditionTarget
|
||||||
|
{
|
||||||
|
Any,
|
||||||
|
Pawn,
|
||||||
|
Animal,
|
||||||
|
Humanlike,
|
||||||
|
Mechanoid,
|
||||||
|
Building,
|
||||||
|
SpecificRaces
|
||||||
|
}
|
||||||
|
}
|
||||||
245
Source/WulaFallenEmpire/Damage/DamageWorker_ExtraDamage.cs
Normal file
245
Source/WulaFallenEmpire/Damage/DamageWorker_ExtraDamage.cs
Normal file
@@ -0,0 +1,245 @@
|
|||||||
|
using System.Collections.Generic;
|
||||||
|
using RimWorld;
|
||||||
|
using Verse;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
|
||||||
|
namespace WulaFallenEmpire
|
||||||
|
{
|
||||||
|
public class DamageWorker_ExtraDamage : DamageWorker
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 重写伤害应用方法
|
||||||
|
/// </summary>
|
||||||
|
public override DamageResult Apply(DamageInfo dinfo, Thing victim)
|
||||||
|
{
|
||||||
|
// 先应用原始伤害
|
||||||
|
DamageResult originalResult = base.Apply(dinfo, victim);
|
||||||
|
|
||||||
|
// 获取额外伤害扩展
|
||||||
|
DamageDef_ExtraDamageExtension extension =
|
||||||
|
dinfo.Def.GetModExtension<DamageDef_ExtraDamageExtension>();
|
||||||
|
|
||||||
|
if (extension != null && victim != null && !victim.Destroyed)
|
||||||
|
{
|
||||||
|
// 应用额外伤害
|
||||||
|
var extraDamageResults = ApplyExtraDamages(extension, dinfo, victim, originalResult);
|
||||||
|
|
||||||
|
// 如果需要,添加战斗日志
|
||||||
|
if (extension.showExtraLog && extraDamageResults.Count > 0)
|
||||||
|
{
|
||||||
|
AddCombatLog(extension, dinfo, victim, extraDamageResults);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return originalResult;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 应用额外伤害
|
||||||
|
/// </summary>
|
||||||
|
private List<DamageResult> ApplyExtraDamages(
|
||||||
|
DamageDef_ExtraDamageExtension extension,
|
||||||
|
DamageInfo originalDinfo,
|
||||||
|
Thing victim,
|
||||||
|
DamageResult originalResult)
|
||||||
|
{
|
||||||
|
List<DamageResult> results = new List<DamageResult>();
|
||||||
|
|
||||||
|
var applicableDamages = extension.GetApplicableExtraDamages(victim, originalDinfo);
|
||||||
|
|
||||||
|
foreach (var extraDamage in applicableDamages)
|
||||||
|
{
|
||||||
|
if (ShouldApplyExtraDamage(extraDamage, originalDinfo, victim))
|
||||||
|
{
|
||||||
|
DamageResult result = ApplySingleExtraDamage(extraDamage, originalDinfo, victim);
|
||||||
|
if (result != null)
|
||||||
|
{
|
||||||
|
results.Add(result);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return results;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 检查是否应该应用额外伤害
|
||||||
|
/// </summary>
|
||||||
|
private bool ShouldApplyExtraDamage(ExtraDamageDef extraDamage, DamageInfo originalDinfo, Thing victim)
|
||||||
|
{
|
||||||
|
// 检查最小触发伤害
|
||||||
|
if (originalDinfo.Amount < extraDamage.minTriggerDamage)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 应用单个额外伤害
|
||||||
|
/// </summary>
|
||||||
|
private DamageResult ApplySingleExtraDamage(ExtraDamageDef extraDamage, DamageInfo originalDinfo, Thing victim)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
// 计算伤害值
|
||||||
|
float damageAmount = extraDamage.CalculateActualAmount(originalDinfo, victim);
|
||||||
|
if (damageAmount <= 0)
|
||||||
|
return null;
|
||||||
|
|
||||||
|
// 计算护甲穿透
|
||||||
|
float armorPenetration = extraDamage.CalculateActualArmorPenetration();
|
||||||
|
|
||||||
|
// 创建伤害信息
|
||||||
|
DamageInfo extraDinfo = new DamageInfo(
|
||||||
|
def: extraDamage.damageDef,
|
||||||
|
amount: damageAmount,
|
||||||
|
armorPenetration: armorPenetration,
|
||||||
|
angle: originalDinfo.Angle,
|
||||||
|
instigator: originalDinfo.Instigator,
|
||||||
|
hitPart: GetTargetBodyPart(victim, extraDamage.targetBodyPart),
|
||||||
|
weapon: originalDinfo.Weapon,
|
||||||
|
category: DamageInfo.SourceCategory.ThingOrUnknown,
|
||||||
|
intendedTarget: originalDinfo.IntendedTarget
|
||||||
|
);
|
||||||
|
|
||||||
|
// 如果是真实伤害,设置特殊标志(如果需要特殊处理)
|
||||||
|
if (extraDamage.isTrueDamage)
|
||||||
|
{
|
||||||
|
// 这里可能需要特殊的处理方式
|
||||||
|
// 例如,可以设置伤害信息中的特殊标志
|
||||||
|
}
|
||||||
|
|
||||||
|
// 应用伤害
|
||||||
|
DamageResult result = victim.TakeDamage(extraDinfo);
|
||||||
|
|
||||||
|
// 播放效果
|
||||||
|
PlayExtraDamageEffects(extraDamage, victim, damageAmount);
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
catch (System.Exception ex)
|
||||||
|
{
|
||||||
|
Log.Warning($"应用额外伤害时出错: {ex.Message}");
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取目标部位
|
||||||
|
/// </summary>
|
||||||
|
private BodyPartRecord GetTargetBodyPart(Thing victim, BodyPartDef bodyPartDef)
|
||||||
|
{
|
||||||
|
if (bodyPartDef == null || !(victim is Pawn pawn))
|
||||||
|
return null;
|
||||||
|
|
||||||
|
return pawn.RaceProps.body.GetPartsWithDef(bodyPartDef).FirstOrDefault();
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 播放额外伤害效果
|
||||||
|
/// </summary>
|
||||||
|
private void PlayExtraDamageEffects(ExtraDamageDef extraDamage, Thing victim, float damageAmount)
|
||||||
|
{
|
||||||
|
if (victim.Map == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
// 播放音效
|
||||||
|
if (extraDamage.soundDef != null)
|
||||||
|
{
|
||||||
|
extraDamage.soundDef.PlayOneShot(new TargetInfo(victim.Position, victim.Map));
|
||||||
|
}
|
||||||
|
|
||||||
|
// 播放粒子效果
|
||||||
|
if (extraDamage.fleckDef != null)
|
||||||
|
{
|
||||||
|
FleckMaker.Static(victim.DrawPos, victim.Map, extraDamage.fleckDef);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 播放效果器
|
||||||
|
if (extraDamage.effecterDef != null)
|
||||||
|
{
|
||||||
|
Effecter effecter = extraDamage.effecterDef.Spawn();
|
||||||
|
effecter.Trigger(new TargetInfo(victim.Position, victim.Map), new TargetInfo(victim.Position, victim.Map));
|
||||||
|
effecter.Cleanup();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 添加战斗日志
|
||||||
|
/// </summary>
|
||||||
|
private void AddCombatLog(
|
||||||
|
DamageDef_ExtraDamageExtension extension,
|
||||||
|
DamageInfo originalDinfo,
|
||||||
|
Thing victim,
|
||||||
|
List<DamageResult> extraResults)
|
||||||
|
{
|
||||||
|
if (victim is Pawn victimPawn)
|
||||||
|
{
|
||||||
|
StringBuilder sb = new StringBuilder();
|
||||||
|
sb.AppendLine($"{extension.extraLabel} - 额外伤害:");
|
||||||
|
|
||||||
|
foreach (var result in extraResults)
|
||||||
|
{
|
||||||
|
if (result != null && result.totalDamageDealt > 0)
|
||||||
|
{
|
||||||
|
sb.AppendLine($" {result.totalDamageDealt:F1} 伤害");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 这里可以添加更详细的战斗日志逻辑
|
||||||
|
// 例如,创建一个自定义的战斗日志条目
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 重写爆炸伤害处理
|
||||||
|
/// </summary>
|
||||||
|
protected override void ExplosionDamageThing(Explosion explosion, Thing t, List<Thing> damagedThings, List<Thing> ignoredThings, IntVec3 cell)
|
||||||
|
{
|
||||||
|
base.ExplosionDamageThing(explosion, t, damagedThings, ignoredThings, cell);
|
||||||
|
|
||||||
|
// 检查并应用额外伤害
|
||||||
|
DamageDef_ExtraDamageExtension extension =
|
||||||
|
explosion.damType.GetModExtension<DamageDef_ExtraDamageExtension>();
|
||||||
|
|
||||||
|
if (extension != null && !t.Destroyed)
|
||||||
|
{
|
||||||
|
// 为爆炸中的每个目标应用额外伤害
|
||||||
|
// 注意:这里需要创建适当的DamageInfo
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 获取伤害描述(用于UI显示)
|
||||||
|
/// </summary>
|
||||||
|
public string GetExtraDamageDescription(DamageDef damageDef)
|
||||||
|
{
|
||||||
|
DamageDef_ExtraDamageExtension extension =
|
||||||
|
damageDef.GetModExtension<DamageDef_ExtraDamageExtension>();
|
||||||
|
|
||||||
|
if (extension == null || extension.extraDamages.Count == 0)
|
||||||
|
return "";
|
||||||
|
|
||||||
|
StringBuilder sb = new StringBuilder();
|
||||||
|
sb.AppendLine("额外伤害效果:");
|
||||||
|
|
||||||
|
foreach (var extraDamage in extension.extraDamages)
|
||||||
|
{
|
||||||
|
string damageType = extraDamage.damageDef.label;
|
||||||
|
string amountStr = extraDamage.isPercentage ?
|
||||||
|
$"{extraDamage.percentageMultiplier * 100}% 原始伤害" :
|
||||||
|
$"{extraDamage.amount} 点";
|
||||||
|
|
||||||
|
sb.AppendLine($" {damageType}: {amountStr}");
|
||||||
|
|
||||||
|
if (extraDamage.minTriggerDamage > 0)
|
||||||
|
{
|
||||||
|
sb.AppendLine($" 触发条件: 原始伤害 > {extraDamage.minTriggerDamage}");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return sb.ToString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -2,20 +2,46 @@ using System.Collections.Generic;
|
|||||||
using RimWorld;
|
using RimWorld;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using Verse;
|
using Verse;
|
||||||
|
using System.Linq;
|
||||||
|
|
||||||
namespace WulaFallenEmpire
|
namespace WulaFallenEmpire
|
||||||
{
|
{
|
||||||
// Final, robust extension class for configuring path-based penetration.
|
|
||||||
public class Wula_PathPierce_Extension : DefModExtension
|
public class Wula_PathPierce_Extension : DefModExtension
|
||||||
{
|
{
|
||||||
// Set to a positive number for limited hits, or -1 for infinite penetration.
|
// 设置正数表示有限命中次数,-1 表示无限穿透
|
||||||
public int maxHits = 3;
|
public int maxHits = 3;
|
||||||
// The percentage of damage lost per hit. 0.25 means 25% damage loss per hit.
|
|
||||||
|
// 每次命中的伤害损失百分比。0.25 表示每次命中损失25%伤害
|
||||||
public float damageFalloff = 0.25f;
|
public float damageFalloff = 0.25f;
|
||||||
// If true, this projectile will never cause friendly fire, regardless of game settings.
|
|
||||||
|
// 如果为 true,无论游戏设置如何,这个抛射体都不会造成友军伤害
|
||||||
public bool preventFriendlyFire = false;
|
public bool preventFriendlyFire = false;
|
||||||
public FleckDef tailFleckDef; // 用于配置拖尾特效的 FleckDef
|
|
||||||
public int fleckDelayTicks = 10; // 拖尾特效延迟生成时间(tick)
|
// 尾部拖尾特效的 FleckDef
|
||||||
|
public FleckDef tailFleckDef;
|
||||||
|
|
||||||
|
// 拖尾特效延迟生成时间(tick)
|
||||||
|
public int fleckDelayTicks = 10;
|
||||||
|
|
||||||
|
|
||||||
|
// 1. 击中敌人时播放的效果器(Effecter)
|
||||||
|
public EffecterDef hitEffecterDef;
|
||||||
|
// 2. 击中敌人时播放的粒子(Fleck)
|
||||||
|
public FleckDef hitFleckDef;
|
||||||
|
// 4. 特效持续时间(tick,仅对效果器有效)
|
||||||
|
public int effectDurationTicks = 60;
|
||||||
|
// 5. 是否对每个命中的敌人都播放特效
|
||||||
|
public bool playEffectOnEveryHit = true;
|
||||||
|
// 6. 特效位置偏移(相对于被击中目标)
|
||||||
|
public Vector3 effectOffset = Vector3.zero;
|
||||||
|
// 7. 特效缩放
|
||||||
|
public float effectScale = 1.0f;
|
||||||
|
// 8. 伤害阈值:只有达到这个伤害值才会播放特效(0表示总是播放)
|
||||||
|
public float damageThreshold = 0f;
|
||||||
|
// 9. 随机播放的特效列表(随机选择一个)
|
||||||
|
public List<EffecterDef> randomHitEffecters;
|
||||||
|
// 10. 随机粒子列表(随机选择一个)
|
||||||
|
public List<FleckDef> randomHitFlecks;
|
||||||
}
|
}
|
||||||
|
|
||||||
public class Projectile_WulaLineAttack : Bullet
|
public class Projectile_WulaLineAttack : Bullet
|
||||||
@@ -23,13 +49,17 @@ namespace WulaFallenEmpire
|
|||||||
private int hitCounter = 0;
|
private int hitCounter = 0;
|
||||||
private List<Thing> alreadyDamaged = new List<Thing>();
|
private List<Thing> alreadyDamaged = new List<Thing>();
|
||||||
private Vector3 lastTickPosition;
|
private Vector3 lastTickPosition;
|
||||||
private int Fleck_MakeFleckTick; // 拖尾特效的计时器
|
private int fleckMakeFleckTick; // 拖尾特效的计时器
|
||||||
public int Fleck_MakeFleckTickMax = 1; // 拖尾特效的生成频率
|
public int fleckMakeFleckTickMax = 1; // 拖尾特效的生成频率
|
||||||
public IntRange Fleck_MakeFleckNum = new IntRange(1, 1); // 每次生成的粒子数量
|
public IntRange fleckMakeFleckNum = new IntRange(1, 1); // 每次生成的粒子数量
|
||||||
public FloatRange Fleck_Angle = new FloatRange(-180f, 180f); // 粒子角度
|
public FloatRange fleckAngle = new FloatRange(-180f, 180f); // 粒子角度
|
||||||
public FloatRange Fleck_Scale = new FloatRange(1f, 1f); // 粒子大小
|
public FloatRange fleckScale = new FloatRange(1f, 1f); // 粒子大小
|
||||||
public FloatRange Fleck_Speed = new FloatRange(0f, 0f); // 粒子速度
|
public FloatRange fleckSpeed = new FloatRange(0f, 0f); // 粒子速度
|
||||||
public FloatRange Fleck_Rotation = new FloatRange(-180f, 180f); // 粒子旋转
|
public FloatRange fleckRotation = new FloatRange(-180f, 180f); // 粒子旋转
|
||||||
|
|
||||||
|
// 特效维护列表
|
||||||
|
private List<Effecter> activeEffecters = new List<Effecter>();
|
||||||
|
private Dictionary<Pawn, int> effecterEndTicks = new Dictionary<Pawn, int>();
|
||||||
|
|
||||||
private Wula_PathPierce_Extension Props => def.GetModExtension<Wula_PathPierce_Extension>();
|
private Wula_PathPierce_Extension Props => def.GetModExtension<Wula_PathPierce_Extension>();
|
||||||
|
|
||||||
@@ -39,10 +69,21 @@ namespace WulaFallenEmpire
|
|||||||
Scribe_Values.Look(ref hitCounter, "hitCounter", 0);
|
Scribe_Values.Look(ref hitCounter, "hitCounter", 0);
|
||||||
Scribe_Collections.Look(ref alreadyDamaged, "alreadyDamaged", LookMode.Reference);
|
Scribe_Collections.Look(ref alreadyDamaged, "alreadyDamaged", LookMode.Reference);
|
||||||
Scribe_Values.Look(ref lastTickPosition, "lastTickPosition");
|
Scribe_Values.Look(ref lastTickPosition, "lastTickPosition");
|
||||||
|
Scribe_Collections.Look(ref activeEffecters, "activeEffecters", LookMode.Deep);
|
||||||
|
Scribe_Collections.Look(ref effecterEndTicks, "effecterEndTicks", LookMode.Reference, LookMode.Value);
|
||||||
|
|
||||||
if (alreadyDamaged == null)
|
if (alreadyDamaged == null)
|
||||||
{
|
{
|
||||||
alreadyDamaged = new List<Thing>();
|
alreadyDamaged = new List<Thing>();
|
||||||
}
|
}
|
||||||
|
if (activeEffecters == null)
|
||||||
|
{
|
||||||
|
activeEffecters = new List<Effecter>();
|
||||||
|
}
|
||||||
|
if (effecterEndTicks == null)
|
||||||
|
{
|
||||||
|
effecterEndTicks = new Dictionary<Pawn, int>();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void Launch(Thing launcher, Vector3 origin, LocalTargetInfo usedTarget, LocalTargetInfo intendedTarget, ProjectileHitFlags hitFlags, bool preventFriendlyFire = false, Thing equipment = null, ThingDef targetCoverDef = null)
|
public override void Launch(Thing launcher, Vector3 origin, LocalTargetInfo usedTarget, LocalTargetInfo intendedTarget, ProjectileHitFlags hitFlags, bool preventFriendlyFire = false, Thing equipment = null, ThingDef targetCoverDef = null)
|
||||||
@@ -51,8 +92,11 @@ namespace WulaFallenEmpire
|
|||||||
this.lastTickPosition = origin;
|
this.lastTickPosition = origin;
|
||||||
this.alreadyDamaged.Clear();
|
this.alreadyDamaged.Clear();
|
||||||
this.hitCounter = 0;
|
this.hitCounter = 0;
|
||||||
// Friendly fire is prevented if EITHER the game setting is true OR the XML extension is true.
|
// 如果游戏设置为 true 或 XML 扩展为 true,则防止友军伤害
|
||||||
this.preventFriendlyFire = preventFriendlyFire || (Props?.preventFriendlyFire ?? false);
|
this.preventFriendlyFire = preventFriendlyFire || (Props?.preventFriendlyFire ?? false);
|
||||||
|
|
||||||
|
// 清理旧的特效器
|
||||||
|
CleanupOldEffecters();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void Tick()
|
protected override void Tick()
|
||||||
@@ -62,39 +106,11 @@ namespace WulaFallenEmpire
|
|||||||
|
|
||||||
if (this.Destroyed) return;
|
if (this.Destroyed) return;
|
||||||
|
|
||||||
this.Fleck_MakeFleckTick++;
|
// 更新拖尾特效
|
||||||
// 只有当达到延迟时间后才开始生成Fleck
|
UpdateTrailFlecks();
|
||||||
if (this.Fleck_MakeFleckTick >= Props.fleckDelayTicks)
|
|
||||||
{
|
|
||||||
if (this.Fleck_MakeFleckTick >= (Props.fleckDelayTicks + this.Fleck_MakeFleckTickMax))
|
|
||||||
{
|
|
||||||
this.Fleck_MakeFleckTick = Props.fleckDelayTicks; // 重置计时器,从延迟时间开始循环
|
|
||||||
}
|
|
||||||
|
|
||||||
Map map = base.Map;
|
// 更新击中特效器
|
||||||
int randomInRange = this.Fleck_MakeFleckNum.RandomInRange;
|
UpdateHitEffecters();
|
||||||
Vector3 currentPosition = this.ExactPosition; // Current position of the bullet
|
|
||||||
Vector3 previousPosition = this.lastTickPosition; // Previous position of the bullet
|
|
||||||
|
|
||||||
for (int i = 0; i < randomInRange; i++)
|
|
||||||
{
|
|
||||||
float currentBulletAngle = ExactRotation.eulerAngles.y; // 使用子弹当前的水平旋转角度
|
|
||||||
float fleckRotationAngle = currentBulletAngle; // Fleck 的旋转角度与子弹方向一致
|
|
||||||
float velocityAngle = this.Fleck_Angle.RandomInRange + currentBulletAngle; // Fleck 的速度角度基于子弹方向加上随机偏移
|
|
||||||
float randomInRange2 = this.Fleck_Scale.RandomInRange;
|
|
||||||
float randomInRange3 = this.Fleck_Speed.RandomInRange;
|
|
||||||
|
|
||||||
if (Props?.tailFleckDef != null)
|
|
||||||
{
|
|
||||||
FleckCreationData dataStatic = FleckMaker.GetDataStatic(currentPosition, map, Props.tailFleckDef, randomInRange2);
|
|
||||||
dataStatic.rotation = fleckRotationAngle;
|
|
||||||
dataStatic.rotationRate = this.Fleck_Rotation.RandomInRange;
|
|
||||||
dataStatic.velocityAngle = velocityAngle;
|
|
||||||
dataStatic.velocitySpeed = randomInRange3;
|
|
||||||
map.flecks.CreateFleck(dataStatic);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (this.Destroyed) return;
|
if (this.Destroyed) return;
|
||||||
|
|
||||||
@@ -105,17 +121,102 @@ namespace WulaFallenEmpire
|
|||||||
this.lastTickPosition = endPos;
|
this.lastTickPosition = endPos;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 更新拖尾粒子特效
|
||||||
|
/// </summary>
|
||||||
|
private void UpdateTrailFlecks()
|
||||||
|
{
|
||||||
|
this.fleckMakeFleckTick++;
|
||||||
|
|
||||||
|
// 只有当达到延迟时间后才开始生成 Fleck
|
||||||
|
if (this.fleckMakeFleckTick >= Props?.fleckDelayTicks)
|
||||||
|
{
|
||||||
|
if (this.fleckMakeFleckTick >= (Props.fleckDelayTicks + this.fleckMakeFleckTickMax))
|
||||||
|
{
|
||||||
|
this.fleckMakeFleckTick = Props.fleckDelayTicks; // 重置计时器,从延迟时间开始循环
|
||||||
|
}
|
||||||
|
|
||||||
|
Map map = base.Map;
|
||||||
|
int randomInRange = this.fleckMakeFleckNum.RandomInRange;
|
||||||
|
Vector3 currentPosition = this.ExactPosition; // 子弹当前位置
|
||||||
|
|
||||||
|
for (int i = 0; i < randomInRange; i++)
|
||||||
|
{
|
||||||
|
float currentBulletAngle = ExactRotation.eulerAngles.y; // 使用子弹当前的水平旋转角度
|
||||||
|
float fleckRotationAngle = currentBulletAngle; // Fleck 的旋转角度与子弹方向一致
|
||||||
|
float velocityAngle = this.fleckAngle.RandomInRange + currentBulletAngle; // Fleck 的速度角度基于子弹方向加上随机偏移
|
||||||
|
float randomInRange2 = this.fleckScale.RandomInRange;
|
||||||
|
float randomInRange3 = this.fleckSpeed.RandomInRange;
|
||||||
|
|
||||||
|
if (Props?.tailFleckDef != null)
|
||||||
|
{
|
||||||
|
FleckCreationData dataStatic = FleckMaker.GetDataStatic(currentPosition, map, Props.tailFleckDef, randomInRange2);
|
||||||
|
dataStatic.rotation = fleckRotationAngle;
|
||||||
|
dataStatic.rotationRate = this.fleckRotation.RandomInRange;
|
||||||
|
dataStatic.velocityAngle = velocityAngle;
|
||||||
|
dataStatic.velocitySpeed = randomInRange3;
|
||||||
|
map.flecks.CreateFleck(dataStatic);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 更新击中特效器
|
||||||
|
/// </summary>
|
||||||
|
private void UpdateHitEffecters()
|
||||||
|
{
|
||||||
|
if (activeEffecters == null || activeEffecters.Count == 0)
|
||||||
|
return;
|
||||||
|
|
||||||
|
var ticksGame = Find.TickManager.TicksGame;
|
||||||
|
var effectersToRemove = new List<Effecter>();
|
||||||
|
var pawnsToRemove = new List<Pawn>();
|
||||||
|
|
||||||
|
// 检查每个特效器是否应该结束
|
||||||
|
foreach (var kvp in effecterEndTicks)
|
||||||
|
{
|
||||||
|
if (ticksGame >= kvp.Value || kvp.Key == null || kvp.Key.Destroyed || !kvp.Key.Spawned)
|
||||||
|
{
|
||||||
|
pawnsToRemove.Add(kvp.Key);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 清理结束的特效器
|
||||||
|
foreach (var pawn in pawnsToRemove)
|
||||||
|
{
|
||||||
|
effecterEndTicks.Remove(pawn);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 清理旧的特效器
|
||||||
|
/// </summary>
|
||||||
|
private void CleanupOldEffecters()
|
||||||
|
{
|
||||||
|
if (activeEffecters != null)
|
||||||
|
{
|
||||||
|
foreach (var effecter in activeEffecters)
|
||||||
|
{
|
||||||
|
effecter?.Cleanup();
|
||||||
|
}
|
||||||
|
activeEffecters.Clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
effecterEndTicks?.Clear();
|
||||||
|
}
|
||||||
|
|
||||||
protected override void Impact(Thing hitThing, bool blockedByShield = false)
|
protected override void Impact(Thing hitThing, bool blockedByShield = false)
|
||||||
{
|
{
|
||||||
CheckPathForDamage(lastTickPosition, this.ExactPosition);
|
CheckPathForDamage(lastTickPosition, this.ExactPosition);
|
||||||
|
|
||||||
if (hitThing != null && alreadyDamaged.Contains(hitThing))
|
if (hitThing != null && alreadyDamaged.Contains(hitThing))
|
||||||
{
|
{
|
||||||
base.Impact(null, blockedByShield);
|
base.Impact(null, blockedByShield);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
base.Impact(hitThing, blockedByShield);
|
base.Impact(hitThing, blockedByShield);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -145,17 +246,17 @@ namespace WulaFallenEmpire
|
|||||||
{
|
{
|
||||||
bool shouldDamage = false;
|
bool shouldDamage = false;
|
||||||
|
|
||||||
// Case 1: Always damage the intended target if it's a pawn. This allows hunting.
|
// 情况1:如果预期目标是pawn,总是造成伤害。这允许狩猎。
|
||||||
if (this.intendedTarget.Thing == pawn)
|
if (this.intendedTarget.Thing == pawn)
|
||||||
{
|
{
|
||||||
shouldDamage = true;
|
shouldDamage = true;
|
||||||
}
|
}
|
||||||
// Case 2: Always damage hostile pawns in the path.
|
// 情况2:总是对路径上的敌对pawn造成伤害。
|
||||||
else if (pawn.HostileTo(this.launcher))
|
else if (pawn.HostileTo(this.launcher))
|
||||||
{
|
{
|
||||||
shouldDamage = true;
|
shouldDamage = true;
|
||||||
}
|
}
|
||||||
// Case 3: Damage non-hostiles (friendlies, neutrals) if the shot itself isn't marked to prevent friendly fire.
|
// 情况3:如果射击本身没有标记为防止友军伤害,则对非敌对(友好,中立)造成伤害。
|
||||||
else if (!this.preventFriendlyFire)
|
else if (!this.preventFriendlyFire)
|
||||||
{
|
{
|
||||||
shouldDamage = true;
|
shouldDamage = true;
|
||||||
@@ -176,12 +277,18 @@ namespace WulaFallenEmpire
|
|||||||
Wula_PathPierce_Extension props = Props;
|
Wula_PathPierce_Extension props = Props;
|
||||||
float falloff = props?.damageFalloff ?? 0.25f;
|
float falloff = props?.damageFalloff ?? 0.25f;
|
||||||
|
|
||||||
// Damage falloff now applies universally, even for infinite penetration.
|
// 伤害衰减现在普遍适用,即使是无限穿透。
|
||||||
float damageMultiplier = Mathf.Pow(1f - falloff, hitCounter);
|
float damageMultiplier = Mathf.Pow(1f - falloff, hitCounter);
|
||||||
|
|
||||||
int damageAmount = (int)(this.DamageAmount * damageMultiplier);
|
int damageAmount = (int)(this.DamageAmount * damageMultiplier);
|
||||||
if (damageAmount <= 0) return;
|
if (damageAmount <= 0) return;
|
||||||
|
|
||||||
|
// 检查伤害阈值
|
||||||
|
if (props?.damageThreshold > 0 && damageAmount < props.damageThreshold)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
var dinfo = new DamageInfo(
|
var dinfo = new DamageInfo(
|
||||||
this.def.projectile.damageDef,
|
this.def.projectile.damageDef,
|
||||||
damageAmount,
|
damageAmount,
|
||||||
@@ -196,6 +303,115 @@ namespace WulaFallenEmpire
|
|||||||
pawn.TakeDamage(dinfo);
|
pawn.TakeDamage(dinfo);
|
||||||
alreadyDamaged.Add(pawn);
|
alreadyDamaged.Add(pawn);
|
||||||
hitCounter++;
|
hitCounter++;
|
||||||
|
|
||||||
|
// 播放击中特效
|
||||||
|
PlayHitEffects(pawn, damageAmount);
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 播放击中敌人时的特效
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="pawn">被击中的Pawn</param>
|
||||||
|
/// <param name="damageAmount">造成的伤害值</param>
|
||||||
|
private void PlayHitEffects(Pawn pawn, int damageAmount)
|
||||||
|
{
|
||||||
|
if (pawn == null || pawn.Destroyed || pawn.Map == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
Wula_PathPierce_Extension props = Props;
|
||||||
|
if (props == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
// 是否对每个命中都播放特效
|
||||||
|
if (!props.playEffectOnEveryHit && hitCounter > 1)
|
||||||
|
return;
|
||||||
|
|
||||||
|
// 播放粒子特效
|
||||||
|
PlayHitFleck(pawn);
|
||||||
|
|
||||||
|
// 播放效果器特效
|
||||||
|
PlayHitEffecter(pawn);
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 播放击中粒子特效
|
||||||
|
/// </summary>
|
||||||
|
private void PlayHitFleck(Pawn pawn)
|
||||||
|
{
|
||||||
|
Wula_PathPierce_Extension props = Props;
|
||||||
|
if (props == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
FleckDef fleckDef = null;
|
||||||
|
|
||||||
|
// 选择粒子:优先使用随机列表,然后使用固定粒子
|
||||||
|
if (props.randomHitFlecks != null && props.randomHitFlecks.Count > 0)
|
||||||
|
{
|
||||||
|
fleckDef = props.randomHitFlecks.RandomElement();
|
||||||
|
}
|
||||||
|
else if (props.hitFleckDef != null)
|
||||||
|
{
|
||||||
|
fleckDef = props.hitFleckDef;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (fleckDef != null)
|
||||||
|
{
|
||||||
|
Vector3 position = pawn.DrawPos + props.effectOffset;
|
||||||
|
float scale = props.effectScale;
|
||||||
|
|
||||||
|
FleckCreationData data = FleckMaker.GetDataStatic(position, pawn.Map, fleckDef, scale);
|
||||||
|
pawn.Map.flecks.CreateFleck(data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 播放击中效果器特效
|
||||||
|
/// </summary>
|
||||||
|
private void PlayHitEffecter(Pawn pawn)
|
||||||
|
{
|
||||||
|
Wula_PathPierce_Extension props = Props;
|
||||||
|
if (props == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
EffecterDef effecterDef = null;
|
||||||
|
|
||||||
|
// 选择效果器:优先使用随机列表,然后使用固定效果器
|
||||||
|
if (props.randomHitEffecters != null && props.randomHitEffecters.Count > 0)
|
||||||
|
{
|
||||||
|
effecterDef = props.randomHitEffecters.RandomElement();
|
||||||
|
}
|
||||||
|
else if (props.hitEffecterDef != null)
|
||||||
|
{
|
||||||
|
effecterDef = props.hitEffecterDef;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (effecterDef != null)
|
||||||
|
{
|
||||||
|
Vector3 position = pawn.DrawPos + props.effectOffset;
|
||||||
|
|
||||||
|
// 创建效果器
|
||||||
|
Effecter effecter = effecterDef.Spawn();
|
||||||
|
effecter.Trigger(new TargetInfo(pawn.Position, pawn.Map), new TargetInfo(pawn.Position, pawn.Map));
|
||||||
|
|
||||||
|
// 如果需要持续效果,添加到维护列表
|
||||||
|
if (props.effectDurationTicks > 0)
|
||||||
|
{
|
||||||
|
activeEffecters.Add(effecter);
|
||||||
|
effecterEndTicks[pawn] = Find.TickManager.TicksGame + props.effectDurationTicks;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// 立即清理效果器
|
||||||
|
effecter.Cleanup();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public override void Destroy(DestroyMode mode = DestroyMode.Vanish)
|
||||||
|
{
|
||||||
|
// 清理所有特效器
|
||||||
|
CleanupOldEffecters();
|
||||||
|
base.Destroy(mode);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
63
Source/WulaFallenEmpire/Verb/Verb_ShootBeyondTarget.cs
Normal file
63
Source/WulaFallenEmpire/Verb/Verb_ShootBeyondTarget.cs
Normal file
@@ -0,0 +1,63 @@
|
|||||||
|
using RimWorld;
|
||||||
|
using System;
|
||||||
|
using UnityEngine;
|
||||||
|
using Verse;
|
||||||
|
|
||||||
|
namespace WulaFallenEmpire
|
||||||
|
{
|
||||||
|
public class Verb_ShootBeyondTarge : Verb_ShootWithOffset
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// 重写射击逻辑,直接修改当前目标为延长线目标
|
||||||
|
/// </summary>
|
||||||
|
protected override bool TryCastShot()
|
||||||
|
{
|
||||||
|
// 保存原始目标
|
||||||
|
LocalTargetInfo originalTarget = currentTarget;
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
// 计算延长线目标
|
||||||
|
LocalTargetInfo beyondTarget = CalculateBeyondTarget(originalTarget);
|
||||||
|
|
||||||
|
// 设置为延长线目标
|
||||||
|
currentTarget = beyondTarget;
|
||||||
|
|
||||||
|
// 调用基类射击逻辑
|
||||||
|
return base.TryCastShot();
|
||||||
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
// 恢复原始目标
|
||||||
|
currentTarget = originalTarget;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 计算延长线目标
|
||||||
|
/// </summary>
|
||||||
|
private LocalTargetInfo CalculateBeyondTarget(LocalTargetInfo target)
|
||||||
|
{
|
||||||
|
if (!target.IsValid || caster == null || caster.Map == null)
|
||||||
|
return target;
|
||||||
|
|
||||||
|
Vector3 shooterPos = caster.DrawPos;
|
||||||
|
Vector3 targetPos = target.HasThing ?
|
||||||
|
target.Thing.DrawPos :
|
||||||
|
target.Cell.ToVector3Shifted();
|
||||||
|
|
||||||
|
Vector3 direction = (targetPos - shooterPos).normalized;
|
||||||
|
float maxRange = EffectiveRange;
|
||||||
|
Vector3 beyondTargetPos = shooterPos + direction * maxRange;
|
||||||
|
IntVec3 beyondTargetCell = beyondTargetPos.ToIntVec3();
|
||||||
|
|
||||||
|
// 确保在地图范围内
|
||||||
|
if (!beyondTargetCell.InBounds(caster.Map))
|
||||||
|
{
|
||||||
|
beyondTargetCell = beyondTargetCell.ClampInsideMap(caster.Map);
|
||||||
|
}
|
||||||
|
|
||||||
|
return new LocalTargetInfo(beyondTargetCell);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -347,6 +347,7 @@
|
|||||||
<Compile Include="HediffComp\HediffComp_TimedExplosion.cs" />
|
<Compile Include="HediffComp\HediffComp_TimedExplosion.cs" />
|
||||||
<Compile Include="Projectiles\Projectile_ConfigurableHellsphereCannon.cs" />
|
<Compile Include="Projectiles\Projectile_ConfigurableHellsphereCannon.cs" />
|
||||||
<Compile Include="Verb\Verb_ShootBeamSplitAndChain.cs" />
|
<Compile Include="Verb\Verb_ShootBeamSplitAndChain.cs" />
|
||||||
|
<Compile Include="Verb\Verb_ShootBeyondTarget.cs" />
|
||||||
<Compile Include="Verb\Verb_ShootShotgun.cs" />
|
<Compile Include="Verb\Verb_ShootShotgun.cs" />
|
||||||
<Compile Include="Projectiles\Projectile_CruiseMissile.cs" />
|
<Compile Include="Projectiles\Projectile_CruiseMissile.cs" />
|
||||||
<Compile Include="Verb\Verb_ShootBeamExplosive\Verb_ShootBeamExplosive.cs" />
|
<Compile Include="Verb\Verb_ShootBeamExplosive\Verb_ShootBeamExplosive.cs" />
|
||||||
|
|||||||
11
mod_D.vdf
Normal file
11
mod_D.vdf
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
|
||||||
|
"workshopitem"
|
||||||
|
{
|
||||||
|
"appid" "294100"
|
||||||
|
"contentfolder" "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\WulaFallenEmpireTest"
|
||||||
|
"previewfile" "D:\\SteamLibrary\\steamapps\\common\\RimWorld\\Mods\\WulaFallenEmpireTest\\About\\Preview.png"
|
||||||
|
"visibility" "3"
|
||||||
|
"title" "Wula Fallen Empire V2"
|
||||||
|
"changenote" "1.6"
|
||||||
|
"publishedfileid" "3604325124"
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user