Can someone help me disable visitors / force certain clothing on them?

Started by Jack Kenseng, April 24, 2016, 09:53:19 PM

Previous topic - Next topic

Jack Kenseng

(This is not so much a mod request but rather a help ME mod request)

So I have a problem with an Ice Sheets biome with -117F winters...every visitor that comes by falls over dead.

I either have to disable them...or force them to show up with high quality muffalo parkas.  Can someone help me with this please?

Mithrawndo

I'm no expert, but I think I know where you want to look: Open up the folder Mods\Core\Defs\PawnKindDefs_Humanlikes\ - inside you'll find files for each kind of faction. The ones who send ground caravans are Outlanders and Tribal. Make backups of these files just now.

You want to find the following lines in the Outlander and Tribal files:

<itemQuality>Poor</itemQuality>

<apparelAllowHeadwearChance>0.4</apparelAllowHeadwearChance>

<apparelMoney>
   <min>300</min>
   <max>900</max>
</apparelMoney>


Raise itemquality to Normal, headwearchance to 1, and have a play around with the min and max money values until you find a setting that doesn't give them gear that's too nice, but gives them enough to survive the cold long enough to provide you with a challenge. There'll still be a chance that some of them will come unprepared for winter due to the fact that some fabrics are of very high value, yet provide no additional bonus to insulation beyond cloth.

Unfortunately, I think these changes may only take effect if you start a new game - someone with more experience will hopefully pop by and confirm. Raiders appear to be generated at the moment of the event and if they survive will be added to your save file, so if you have an existing save you'll need to open the save file up in your favourite text editor and locate the section called <worldPawns>: inside this, locate <apparel> for each and ensure every pawn has lines that look a little like this. Do vary a little, as otherwise everyone will turn up in identical clothes!:

<apparel>
<wornApparel>
<li>
<def>Apparel_BasicShirt</def>
<id>Apparel_BasicShirt6</id>
<pos>(-1000, -1000, -1000)</pos>
<health>100</health>
<stackCount>1</stackCount>
<stuff>MuffalloWool</stuff>
<quality>Good</quality>
</li>
<li>
<def>Apparel_Pants</def>
<id>Apparel_Pants9</id>
<pos>(-1000, -1000, -1000)</pos>
<health>99</health>
<stackCount>1</stackCount>
<stuff>MuffaloWool</stuff>
<color>RGBA(0.632, 0.716, 0.856, 1.000)</color>
<colorActive>True</colorActive>
<quality>Normal</quality>
</li>
<li>
<def>Apparel_Parka</def>
<id>Apparel_Parka8</id>
<pos>(-1000, -1000, -1000)</pos>
<health>172</health>
<stackCount>1</stackCount>
<stuff>MuffaloWool</stuff>
<quality>Shoddy</quality>
</li>
                                                        <li>
<def>Apparel_Tuque</def>
<id>Apparel_Tuque91240</id>
<pos>(-1000, -1000, -1000)</pos>
<health>97</health>
<stackCount>1</stackCount>
<stuff>MuffaloWool</stuff>
<color>RGBA(0.900, 0.900, 0.900, 1.000)</color>
<colorActive>True</colorActive>
<quality>Normal</quality>
</li>
</wornApparel>
<lastApparelWearoutTick>300250</lastApparelWearoutTick>
</apparel>


Most of these are pretty straightforward:
<def> chooses the category of clothing
<id> the specific item
<pos> places them on the map (-1000 seems to indicate that they're coming from off planet.)
<health> is how many hitpoints the item has left
<stackCount> is how many of that item they're carrying
<stuff> determines what textile is used
<color> colours the item using Red, Green, Blue and Alpha respectively
<colorActive> I assume toggles whether an item is coloured or not (so that the pawns have individuality without looking like mardi-gras
<quality> is the build quality.

Hope this all makes sense and I'm sorry if I omitted something. Please make backups, as I've been away for over 30 hours now and so my brain probably isn't working as well as it should and there's every chance I missed something important!

Shinzy

if you just want visitors (and invaders) to not freeze to death
here, I made this (See attachments)

It's a quick mod that adds a "cloak" with 100 cold insulation that *should* spawn for all the new visitors
It'll be destroyed if you try to loot it, or recruit someone wearing it


But the above should work fine, too! (and the changes should take place immediately no need for a new game)

[attachment deleted by admin - too old]

Jack Kenseng

...Whoa, Shinzy, that's awesome.

But I kinda have another problem...

Can someone tell me how to raise the cold tolerance of Muffalo?  :o  Because Traders pack gear on them and even those drop dead at -117F.

Edit: I found the "ComfyTemperature" value after an hour of searching...I'll give that a try.

Bodog999

Change the

     <ComfyTemperatureMin>-45</ComfyTemperatureMin>

Line into something like:

     <ComfyTemperatureMin>-100</ComfyTemperatureMin>

Britnoth

<commonality>20</commonality>

Aha! this is how you get everypawn to wear an item without overwriting pawnkinddefs??

I need to change my monkeys mod I guess....

But this mod as is has the problem that the cloak is too good... if you give pawns an item that is better cold protection than a parka.. then raiders will no longer spawn with any parkas. Which somewhat sucks on the ice sheet.  :D