RimWorld

RimWorld

Early Times
henk 17 Jan, 2022 @ 4:53am
Failed to add recipes to Thinking spot, when using JPT[Human Resources]
I have no clue what's going wrong here, I tried to fix it myself but I am litteraly green at modding. Secondly I use the GoG version so I can't post in comments sadly enough

HugsLib
https://gist.github.com/d1a1aff47adfbca3cc4cdb6e0ae5dc29

It's regarding 2 patches that add the bookshelf and the recipes from Human Resources to the thinkingspot, if this doesn't happen you can't advance in tech due to lack of the tech 'methodical research'

I worked around it by giving that knowledge to my starters, but I don't know how to fix the patch itself.

<?xml version="1.0" encoding="utf-8" ?>

<Patch>

<!--Add TS_ThinkingSpot to Workgiver-->
<Operation Class="PatchOperationAdd">
<xpath>/Defs/WorkGiverDef[defName = "Research"]/fixedBillGiverDefs</xpath>
<value>
<li>TS_ThinkingSpot</li>
</value>
</Operation>
<!--Add TS_ThinkingSpot to Recipe-->
<Operation Class="PatchOperationAdd">
<xpath>/Defs/RecipeDef[defName = "ResearchTech"]/recipeUsers</xpath>
<value>
<li>TS_ThinkingSpot</li>
</value>
</Operation>
<!--Add Bill and Bookshelf to TS_ThinkingSpot-->
<Operation Class="PatchOperationReplace">
<xpath>/Defs/ThingDef[defName = "TS_ThinkingSpot"]/thingClass</xpath>
<value>
<thingClass>Building_WorkTable</thingClass>
</value>
</Operation>
<Operation Class="PatchOperationAdd">
<xpath>/Defs/ThingDef[defName = "TS_ThinkingSpot"]</xpath>
<value>
<inspectorTabs>
<li>ITab_Bills</li>
</inspectorTabs>
</value>
</Operation>
<Operation Class="PatchOperationConditional">
<xpath>/Defs/ThingDef[defName = "TS_ThinkingSpot"]/comps</xpath>
<match Class="PatchOperationConditional">
<xpath>/Defs/ThingDef[defName = "TS_ThinkingSpot"]/comps/li/linkableFacilities</xpath>
<nomatch Class="PatchOperationAdd">
<xpath>/Defs/ThingDef[defName = "TS_ThinkingSpot"]/comps</xpath>
<value>
<li Class="CompProperties_AffectedByFacilities">
<linkableFacilities />
</li>
</value>
</nomatch>
</match>
<nomatch Class="PatchOperationAdd">
<xpath>/Defs/ThingDef[defName = "TS_ThinkingSpot"]</xpath>
<value>
<comps>
<li Class="CompProperties_AffectedByFacilities">
<linkableFacilities />
</li>
</comps>
</value>
</nomatch>
</Operation>
<Operation Class="PatchOperationAdd">
<xpath>/Defs/ThingDef[defName = "TS_ThinkingSpot"]/comps/li/linkableFacilities</xpath>
<value>
<li>BookShelf</li>
</value>
</Operation>

</Patch>

and

<?xml version="1.0" encoding="utf-8" ?>

<Patch>

<Operation Class="PatchOperationAdd">
<xpath>/Defs/ThingDef[defName="StudyDesk"]</xpath>
<value>
<researchPrerequisites>
<li>TS_MethodicalResearch</li>
</researchPrerequisites>
</value>
</Operation>

<Operation Class="PatchOperationAdd">
<xpath>/Defs/ThingDef[defName="BookShelf"]</xpath>
<value>
<researchPrerequisites>
<li>TS_MethodicalResearch</li>
</researchPrerequisites>
</value>
</Operation>

<Operation Class="PatchOperationAdd">
<xpath>/Defs/ThingDef[defName="MrDummy"]</xpath>
<value>
<researchPrerequisites>
<li>MedTimes_WeaponsMetal</li>
<li>TS_MethodicalResearch</li>
</researchPrerequisites>
</value>
</Operation>
<Operation Class="PatchOperationAdd">
<xpath>/Defs/ThingDef[defName="Target"]</xpath>
<value>
<researchPrerequisites>
<li>MedTimes_Crossbow</li>
<li>TS_MethodicalResearch</li>
</researchPrerequisites>
</value>
</Operation>
</Patch>


- Study Desk doesn't contain proper recipes
- Thinking Spot doesn't
- Can't advance in tech at all this way, I guess it's a simple xml fix?
Last edited by henk; 17 Jan, 2022 @ 4:56am