边缘世界 RimWorld

边缘世界 RimWorld

Rim of Madness x Medieval Overhaul Bones Compatibility
#6 2022 年 2 月 28 日 下午 7:05
Mod compat request
Hello, I have a mod which allows to butcher rotten corpses to receive bones from the Rim of Madness Bones mod, I've been thinking on how to add compat to Medieval Overhaul and have come to the conclusion that it may make more sense for you to patch my mod from your end rather than me doing it from my end because if I do it then I'd have to basically recreate your mod entirely in order to have the same clean integration with Medieval Overhaul.

If you find this to be agreeable then all you'd need to do is add this patch to your mod.

<?xml version="1.0" encoding="utf-8" ?> <Patch> <Operation Class="PatchOperationSequence"> <success>Always</success> <operations> <li Class="PatchOperationTest"> <xpath>Defs/ThingDef[defName = "DankPyon_Bone"]</xpath> </li> <li Class="PatchOperationReplace"> <xpath>Defs/RecipeDef[defName = "ButcherCorpseRotten"]/products</xpath> <value> <products> <DankPyon_Bone>25</DankPyon_Bone> </products> </value> </li> </operations> </Operation> </Patch>
最后由 #6 编辑于; 2022 年 2 月 28 日 下午 7:06
< >
正在显示第 1 - 4 条,共 4 条留言
Holgast  [开发者] 2022 年 3 月 28 日 下午 7:41 
Hmm. I don't see how this is relevant to my mod, you can easily do this yourself.
You could put in a patch where if both Med Overhaul and Rim of Madness Bones are installed, it only creates bones for whichever one you like most. Check out the PatchOperations page on the wiki, you can use a FindMod operation to only apply patches when a mod is enabled. For something like that you would use two nested findmod operations to run it only when both mod conditions are met. Then you can add your recipe into a regular findmod for people who are only using Medieval Overhaul or Rim of Madness Bones. Then remove the dependencies for RoM Bones and people who use either or both will get the correct outcome. You can also use XML Extensions to add a mod menu where people who prefer the other outcome for both mods running to be able to change it for their install.

However, if you just want me to put in a compat patch for my mod that makes people also using yours get the right bone instead, I can do that ;)
最后由 Holgast 编辑于; 2022 年 3 月 28 日 下午 7:45
Holgast  [开发者] 2022 年 3 月 28 日 下午 7:42 
Feel free to contact me on the RW discord if you need more help on how to accomplish this. You can look at patches for most other mods to see how the findmod operation works in more detail, I use some nested ones in some of my mods as well.
#6 2022 年 3 月 29 日 上午 1:46 
I've got a basic patch working for now, I'll have it uploaded this evening.
RandomEdits 1 月 31 日 上午 7:19 
Could you make a compatibility patch for Outland - Core?
< >
正在显示第 1 - 4 条,共 4 条留言
每页显示数: 1530 50