RimWorld

RimWorld

Orbital Book Merchants
Improved compatibility
Hi! Great mod! As I've been fooling around with books lately, I have ideas for better mod compatibility for you:

A patch to add a "Books" tradeTag to BookBase:

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


<Operation Class="PatchOperationAdd">
<xpath>Defs/ThingDef[@Name="BookBase"]</xpath>
<value>
<tradeTags>
<li>Books</li>
</tradeTags>
</value>
</Operation>

</Patch>

Then, add the following to your trader def:

<li Class="StockGenerator_MarketValue">
<tradeTag>Books</tradeTag>
<countRange>20~40</countRange>
</li>


(or whatever countRange you wanted)

That will then ensure any book inheriting from BookBase (all of them basically, modded or otherwise) is stocked by your trader. You could keep your SingleDefs also to add more of individual types, etc.

Cheers!