Meat Texture Paths

Started by jabbamonkey, December 26, 2018, 01:29:49 AM

Previous topic - Next topic

jabbamonkey

I am looking to replace the default MEAT textures in the game. I created the following images...

Meat_Big_a.png
Meat_Big_b.png
Meat_Big_c.png
Meat_Small_a.png
Meat_Small_b.png
Meat_Small_c.png
Meat_Human_a.png
Meat_Human_b.png
Meat_Human_c.png
Meat_Insect_a.png
Meat_Insect_b.png
Meat_Insect_c.png

The problem is ... I don't know where to place these images in my mods textures folder.  I searched the core DEF folder for documents containing the word "meat" and got plenty of results, but none that showed the path for the meats.  Can anyone tell me what folders I need (and how to find this out in the future)?  And, what folder structure I should use? 

I tried putting the images all in ...
Textures\Things\Item\Resource
but that didn't work... so I tried ...
Textures\Things\Item
... but that didn't work ... so I tried to put them all in their own folders... for example:
Textures\Things\Item\Resource\Meat_Big
... still didn't work

Also, is there a way to check an items texture path IN-GAME?  For example, using the development tools?  I can select an item (with the magnifying glass def tool selected) and find out the DefName... but not the texture path (and sometimes the defName isn't useful... in the case of Meat or Leathers)

jabbamonkey

I stumbled onto this thread which helped...

https://www.reddit.com/r/RimWorld/comments/9c0jgd/b19_how_to_mod_stack_textures_for_items_like_meat/

It says that meat is in a folder called MeatFoodRaw (and each type should have it's own folder).

Does anyone know how you find this out in the game? In the files?  Anywhere else?  I had to ask around, instead of look somewhere specific.

Mehni

C#.

Meat and corpses aren't defined in the xml, they're generated from Pawns in C#. ThingDefGenerator_Meat is the class.

if (sourceDef.race.Humanlike)
{
d.graphicData.texPath = "Things/Item/Resource/MeatFoodRaw/Meat_Human";
}
else if (sourceDef.race.FleshType == FleshTypeDefOf.Insectoid)
{
d.graphicData.texPath = "Things/Item/Resource/MeatFoodRaw/Meat_Insect";
}
else if (sourceDef.race.baseBodySize < 0.7f)
{
d.graphicData.texPath = "Things/Item/Resource/MeatFoodRaw/Meat_Small";
}
else
{
d.graphicData.texPath = "Things/Item/Resource/MeatFoodRaw/Meat_Big";
}