-
Notifications
You must be signed in to change notification settings - Fork 3
A Dog Said... patching guide
Whenever a mod adds animals, it seems to be expected that it adds a patch for A Dog Said.... It seems that it's not uncommon to download a patch template, fill it out and then release a patch mod.
This is not an ideal solution. The user will have to pay attention to not only the mod itself, but also a patch for it and only add it if a third patch is loaded. Also even though all the templates provides the same result ingame, not all of them are equally fast. In fact some are dead slow compared to some other templates.
This page provides a template, which makes use of ModCheck to make an included patchmod, which eliminates the need for a standalone patchmod. On top of that the template aims to be as fast as possible.
Usage guide is in the start of the file as comments.
<?xml version="1.0" encoding="utf-8" ?>
<!--
template for patching for A Dog Said...
Downloaded from: https://github.com/Nightinggale/ModCheck/wiki/A-Dog-Said...-patching-guide
ModCheck allows including it in the mod itself and only activate as needed.
This will eliminate the need for a standalone patchmod.
Usage: replace AnimalA, AnimalB etc with your animals.
Delete any recipes, which doesn't apply to your animal.
If some parts doesn't apply to all your animals, you should copy paste PatchOperationAdd.
Say only half the animals have tails. Make a copy PatchOperationAdd, delete all references
to tails and then delete all references to non-tail objects in the copy.
Be aware that the first item doesn't start with or while the rest does.
Also be aware that each PatchOperationAdd takes around the same time regardless of how many
recipes it triggers on. This mean you should split into multiple if you need it for game
values, but not if it's just because "it looks nicer".
-->
<Patch>
<Operation Class="ModCheck.Sequence">
<patchName>Patching for A Dog Said...</patchName>
<operations>
<li Class="ModCheck.IsModLoaded">
<modName>A Dog Said...</modName>
</li>
<li Class="PatchOperationAdd">
<xpath>Defs/RecipeDef[defName =
"OldWoundsAnimal"
or "InstallSimpleProstheticTailAnimal"
or "InstallPowerClawAnimal"
or "InstallPegLegAnimal"
or "InstallSimpleProstheticLegAnimal"
or "InstallBionicLegAnimal"
or "InstallSimpleProstheticArmAnimal"
or "InstallBionicArmAnimal"
or "InstallNoseAnimalSimple"
or "InstallBionicEyeAnimal"
or "InstallEarAnimalSimple"
or "InstallEarAnimalBionic"
or "InstallJawAnimalSimple"
or "InstallJawAnimalBionic"
or "InstallSpineAnimalSimple"
or "InstallSpineAnimalBionic"
or "InstallAnimalBrainStimulator"
or "InstallBionicAnimalHeart"
or "InstallBionicAnimalLung"
or "InstallBionicAnimalLiver"
or "InstallBionicAnimalKidney"
or "InstallBionicAnimalStomach"
]/recipeUsers</xpath>
<value>
<li>AnimalA</li>
<li>AnimalB</li>
<li>AnimalC</li>
</value>
</li>
</operations>
</Operation>
</Patch>