边缘世界 RimWorld

边缘世界 RimWorld

LightsOut
Zarii 12 月 3 日 下午 3:54
Dubs Ceiling Fans Workaround
I really like this mod, but I was bothered by the ceiling fans not working. I understand why they don't, and so I made a small patch to work around this. It turns off the light of the fan (permanently) and cuts the base power consumption by half, since the fan is now only doing half the job. This allows you to place another light in the room, that will work, while still gaining the fan cooling benefit.

<Patch> <Operation Class="PatchOperationFindMod"> <mods> <li>Dubs Bad Hygiene</li> </mods> <match Class="PatchOperationSequence"> <success>Always</success> <operations> <li Class="PatchOperationReplace"> <xpath>/Defs/ThingDef[@Name="BasedCeilingFan"]/costList/Steel</xpath> <value> <!--A little less steel since it isn't a light anymore. --> <Steel>30</Steel> </value> </li> <li Class="PatchOperationReplace"> <xpath>/Defs/ThingDef[@Name="BasedCeilingFan"]/statBases/Mass</xpath> <value> <!--A little less weight --> <Mass>8</Mass> </value> </li> <li Class="PatchOperationReplace"> <xpath>/Defs/ThingDef[@Name="BasedCeilingFan"]/comps/li[@Class="CompProperties_Power"]/basePowerConsumption</xpath> <value> <!--halve the power consumption, since the fan no longer lights up --> <basePowerConsumption>25</basePowerConsumption> </value> </li> <li Class="PatchOperationRemove"> <!--Remove the colored lights upgrade since this is now a basic fan--> <xpath>/Defs/ThingDef[@Name="BasedCeilingFan"]/comps/li[@Class="CompProperties_Power"]/powerUpgrades</xpath> </li> <li Class="PatchOperationReplace"> <xpath>/Defs/ThingDef[@ParentName="BasedCeilingFan"][defName="CeilingFan"]/label</xpath> <value> <!-- Since we're here, fix the label --> <label>Ceiling Fan 2 x 2</label> </value> </li> <li Class="PatchOperationRemove"> <!-- remove only the glower, in case someone else needs the comps tag--> <xpath>/Defs/ThingDef[@ParentName="BasedCeilingFan"][defName="CeilingFan"]/comps/li[@Class="CompProperties_Glower"]</xpath> </li> <li Class="PatchOperationReplace"> <xpath>/Defs/ThingDef[@ParentName="BasedCeilingFan"][defName="CeilingFanS"]/label</xpath> <value> <label>Ceiling Fan 1 x 1</label> </value> </li> <li Class="PatchOperationRemove"> <xpath>/Defs/ThingDef[@ParentName="BasedCeilingFan"][defName="CeilingFanS"]/comps/li[@Class="CompProperties_Glower"]</xpath> </li> </operations> </match> </Operation> </Patch>
< >
正在显示第 1 - 1 条,共 1 条留言
Zarii 12 月 3 日 下午 6:44 
To use this, open a text editor and copy paste this code into a new file. Save it as xml to Mods/Lights Out/Patches with an appropriate filename. I named mine DBHCeilingFan.xml
< >
正在显示第 1 - 1 条,共 1 条留言
每页显示数: 1530 50