RimWorld

RimWorld

Not enough ratings
Patch Example mod
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
3.814 KB
28 Oct, 2017 @ 8:19am
4 Nov, 2017 @ 6:51am
2 Change Notes ( view )

Subscribe to download
Patch Example mod

Description
This mod contains a patch of how to use the patch operators to make updates to mods.

I have made this mod public as it explains how to use the patches to update defs of other mods. In the case of this example I have made an exampledef in the defs folder while the patch is in the patch folder which is required by the game to make sure the patch works. Subfolders in the defs and patches folders can be made as you wish. i hope this will help other modders to better understand how to use patches.

To get a working example of a patchmod take a look at the Firepit and Sconces + Enhanced woodworking patch I have published as I made it for myself.
8 Comments
TurtleShroom 26 Sep, 2021 @ 5:37pm 
Are you still making these tutorials?
AncientGatekeeper 6 Jun, 2019 @ 6:28pm 
Can you update this mod since with 1.0, some of the older coding reqs changed. Would really help when I create patches for some of my fave mods. Thanks!
Raszagal  [author] 4 Nov, 2017 @ 6:51am 
Updated to use the more performance efficient xpathing
Raszagal  [author] 3 Nov, 2017 @ 11:01am 
Yeah, I need to update that. I just wrote the xpath queries quickly so that they would function and made an explenation for the xpathing itself and what is possible to filter with it.
FrozenSnowFox 1 Nov, 2017 @ 3:31pm 
Why are all of your examples using // ? They should be using */, using // absolutely murders performance. You comment in the file even mentions this.

https://ludeon.com/forums/index.php?topic=32874.0
Raszagal  [author] 29 Oct, 2017 @ 4:19am 
Especially the need to have the patch in a patches folder is something one can read over so make sure you don't forget that if you make your own
Raszagal  [author] 29 Oct, 2017 @ 4:17am 
I hope it helps cause I had to dig on the forums and tutorials to see how it works and even then you need to look at a different tutorial for xpathing. I included in the patch file a basic xpath tutorial with examples of what they can be.
Cotton Joe 28 Oct, 2017 @ 8:48pm 
Thanks!