Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - jabbamonkey

#1
Help / Path to Meal Images
August 08, 2022, 05:40:49 PM
So, I had created a texture mod during v1.2 ... and I saw that my mod had some errors during the last update (it was awhile ago, but I haven't had time to address it, so here I am now). The meal images are all broken now.  The path to my meal images were ...

Things/Items/Meal/Fine/Fine_a.png
Things/Items/Meal/Fine/Fine_b.png  (mid stack)
Things/Items/Meal/Fine/Fine_c.png  (full stack)
Things/Items/Meal/Lavish/Lavish_a.png
Things/Items/Meal/Lavish/Lavish_b.png
Things/Items/Meal/Lavish/Lavish_c.png
Things/Items/Meal/NutrientPaste/NutrientPaste_a.png
Things/Items/Meal/NutrientPaste/NutrientPaste_b.png
Things/Items/Meal/NutrientPaste/NutrientPaste_c.png
Things/Items/Meal/Simple/Simple_a.png
Things/Items/Meal/Simple/Simple_b.png
Things/Items/Meal/Simple/Simple_c.png
Things/Items/Meal/SurvivalPack/SurvivalPack_a.png
Things/Items/Meal/SurvivalPack/SurvivalPack_b.png
Things/Items/Meal/SurvivalPack/SurvivalPack_c.png

I checked the SOURCE ARTWORK, but those paths seem correct. Yet, I'm getting error messages and the images aren't showing up in game...

Any idea how to fix this?

Note: I did increase the resolution of the images. I think the original were 64x64 ... and I bumped them up to 128x128 (maybe 256).  Would that cause the issue?
#2
Checking to see if something is there first, is a safe thing to do (and avoids issues in the future).

I can JUST REPLACE ... then I'd get an error if it doesn't exist.

If I JUST ADD, then I'd get an error if it does exist already.
#3
I sort of WANT to do that, to make the mod as good as possible ... BUT, I also don't want to do that, because I'll be "pulling out my hair" trying to figure it HOW to do it.
:)
#4
Help / Re: Replacing Textures for Prosthetics
April 20, 2021, 02:19:55 PM
Quote from: Canute on April 20, 2021, 12:43:05 PM
jabba,
you need to go back to the editor! :-(
When i just activate the mod alone i am geting...

Hey Canute,
Someone else mentioned issues with the Tailor workbench and a few other mods... so I just updated my mod, and I removed all instances of the Tailor workbench (hand an electric), so you shouldn't be getting any errors anymore. Check and let me know. Thanks!

Note: My mods are all texture changes, so they wont affect save games.
#5
Help / How to Create a Settings Page for Mod
April 20, 2021, 02:12:49 PM
I was hoping to upgrade my mod... At the moment, the mod just replaces the textures for a TON of items in the game. Alot of people love the textures, but occasionally someone will say something like, "Can you create a mod just with User Interface Icons" .... Or, "Can you create a mod without the statue textures?"

So.... I'd like to have a mod setting page (similar to other mods), where users can "deactivate" some of the texture changes. For example, some people don't like my "statue" textures. So, I'd like them to be able to go into the settings page, and  "disable" the texture replacements for the statues (by "unchecking" that line item). 

Now, the problem is, I don't even know where to start with this. Is there a tutorial for this kind of things? (a VERY BASIC tutorial, because I'm a designer, and not a true programmer)   :)

Or, ideally, has someone does this for a few textures, and have an example out there that I can "tweak"?  Let me know...
#6
Help / Re: Replacing Textures for Prosthetics
April 20, 2021, 12:30:04 PM
THAT'S IT!!!!!

I uploaded an image to the mod page, showing all the body parts and prosthetics (3rd image in the list)
https://steamcommunity.com/sharedfiles/filedetails/?id=2460633890

Thanks alot!!!
#7
Well, I tend to use Gloomy's Production/Furniture mods AFTER my mod, and they replace the TailorBench as well. So, I am assuming that their TailorBench code OVERRIDES mine....

Yup, just removed Gloomy's mods and the error showed up on my game load. I'll just remove the code from my mod. Thanks!
#8
Help / Re: Replacing Textures for Prosthetics
April 20, 2021, 08:37:04 AM
Crap ... was I looking at the wrong mod?  Grrrrrr....

So, ArchotechEar definitely exists in my game (when I create a stockpile, I have a whole list of Archotech items, including an ArchotechEar). 

Let's me try this again... So, I searched my RimWorld Workshop folder for xml patches containing "ArchotechEar" ... and the only mention of ArchotechEar that came up was from the mod "Save Our Ship 2" in the "1909914131/1.2/Defs/Misc/ArchotechGifts.xml" file. Here is that mention ...

<ArchotechGiftDef>
    <defName>ArchotechEar</defName>
<research>SoSArchotechOrgans</research>
<thing>SoSArchotechEar</thing>
  </ArchotechGiftDef>


That seems odd... because there is no other DEF information on ArchotechEar (no info on how the bionic part improves a pawn, surgery information, etc.). But, there are a TON of cs files. There are a few that mention "Archo" ... one called "QuestNode_GenerateThingSetArchotech.cs" which details individual Archotech items:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Verse;

namespace RimWorld.QuestGen
{
    class QuestNode_GenerateThingSetArchotech : QuestNode
    {
public SlateRef<FloatRange?> totalMarketValueRange;

public SlateRef<QualityGenerator?> qualityGenerator;

protected override void RunInt()
        {
Slate slate = QuestGen.slate;
ThingSetMakerParams parms = default(ThingSetMakerParams);
parms.totalMarketValueRange = totalMarketValueRange.GetValue(slate);
parms.qualityGenerator = qualityGenerator.GetValue(slate);
parms.techLevel = TechLevel.Archotech;
ThingSetMaker maker = new ThingSetMaker_ArchotechGift();

List<Thing> list = maker.Generate(parms);
QuestPart_Choice choice = new QuestPart_Choice();
choice.choices = new List<QuestPart_Choice.Choice>();
QuestPart_Choice.Choice theChoice = new QuestPart_Choice.Choice();
Reward_Items items = new Reward_Items();
items.items = list;
theChoice.rewards.Add(items);
QuestPart_ArchotechSpawn spawn = new QuestPart_ArchotechSpawn();
spawn.mapParent = QuestGen.slate.Get<Map>("map").Parent;
spawn.Things = list;
spawn.quest = QuestGen.quest;
spawn.inSignal = slate.Get<string>("inSignal");
theChoice.questParts.Add(spawn);
QuestGen.quest.AddPart(spawn);
choice.choices.Add(theChoice);

list = maker.Generate(parms);
theChoice = new QuestPart_Choice.Choice();
items = new Reward_Items();
items.items = list;
theChoice.rewards.Add(items);
spawn = new QuestPart_ArchotechSpawn();
spawn.mapParent = QuestGen.slate.Get<Map>("map").Parent;
spawn.Things = list;
spawn.quest = QuestGen.quest;
spawn.inSignal = slate.Get<string>("inSignal");
theChoice.questParts.Add(spawn);
QuestGen.quest.AddPart(spawn);
choice.choices.Add(theChoice);

list = maker.Generate(parms);
theChoice = new QuestPart_Choice.Choice();
items = new Reward_Items();
items.items = list;
theChoice.rewards.Add(items);
spawn = new QuestPart_ArchotechSpawn();
spawn.mapParent = QuestGen.slate.Get<Map>("map").Parent;
spawn.Things = list;
spawn.quest = QuestGen.quest;
spawn.inSignal= slate.Get<string>("inSignal");
theChoice.questParts.Add(spawn);
QuestGen.quest.AddPart(spawn);
choice.choices.Add(theChoice);

QuestGen.quest.AddPart(choice);
choice.quest = QuestGen.quest;
}

        protected override bool TestRunInt(Slate slate)
        {
            return true;
        }
    }
}



I don't know how to edit CS files at all... I'm hoping I can just change things using XML (which I only know a bit).

Note: There are a bunch of other CS files containing Archotech ... noteable ones were QuestPart_ArchotechSpawn.cs and QuestNode_ArchotechSpawn.cs
#9
Help / Re: Replacing Textures for Prosthetics
April 18, 2021, 08:39:01 PM
Quote from: Fakeaccount123 on April 18, 2021, 08:16:50 PM
I´m not sure if we are talking about the same mod but the "ParentName" of archotech implants in Expanded Prosthetics and Organ Engineering is not ArchotechBase, is "Glitterworld". Which are specifically the implants/body parts you can´t patch?

Code in the mod states:
<ThingDef Name="ArchotechBase" ParentName="BodyPartModBase" Abstract="True">
#10
Help / Re: Replacing Textures for Prosthetics
April 18, 2021, 09:57:21 AM
QuoteMy suggestion, try to look at
Body Parts Textures
https://steamcommunity.com/sharedfiles/filedetails/?id=2439038368
how he did the patches.

I tried that... getting an error using their code too....
#11
Help / Re: Replacing Textures for Prosthetics
April 18, 2021, 08:27:55 AM
I placed in all the code (and the extra lines for each item...). But, getting an error and the inidividual graphics still aren't showing up (just the default Bionics2 image). Looks like an error with REMOVING the ArchotechBase texPath....

Quote[Jabbamonkey's HIRES Graphic Overhaul] Patch operation Verse.PatchOperationSequence(count=108, lastFailedOperation=Verse.PatchOperationRemove(/Defs/ThingDef[defName = "ArchotechBase"]/graphicData/texPath)) failed

#12
I created some updated WORKBENCHES in a mod, and this required editing the Def for the masking. One person said they are getting an error and seeing a red X for a workbench. I think this may be an issue with conflicting mods that affect the workbenches I edited. Can someone help me fix the code, so it overrides other mods (my knowledge of XML is VERY limited) .....

Here are the two error messages...
Quote1)
XML error: Duplicate XML node name shaderType in this XML block: <graphicData><texPath>Things/Building/Production/TableTailorHand</texPath>

2)
XML Verse.GraphicData defines the same field twice: shaderType.
Field contents: CutoutComplex.
Whole XML:
<graphicData><texPath>Things/Building/Production/TableTailorHand</texPath>

Here is an example of the modified workbench code:
<li Class="patchOperationAdd">
<success>Always</success>
<xpath>*/ThingDef[defName = "HandTailoringBench"]/graphicData</xpath>
<value>
<shaderType>CutoutComplex</shaderType>
</value>
</li>


Note: I  know the image path is correct, and I am not receiving errors on my end. Also, the user didn't provide their log, so I don't know what mods could be affecting this.
#13
Help / Re: Replacing Textures for Prosthetics
April 17, 2021, 02:34:31 PM
Yeah, the game versions kept changing, so I found it hard to keep up with updating the mods... and took a break for awhile.

But, back to the problem.....
As I mentioned, my XML knowledge is VERY limited. I got the following error (with the code I tried below):

Quote
XML error: <value><graphicData><texPath>Things/Item/BodyPart/Bionic2</texPath></graphicData></value> doesn't correspond to any field in type PatchOperationRemove. Context: <li Class="PatchOperationRemove"><xpath>Defs/ThingDef[defName = "ArchotechBase"]</xpath><value><graphicData><texPath>Things/Item/BodyPart/Bionic2</texPath></graphicData></value></li>


[MyMod]Patch operation Verse.PatchOperationSequence(count=109, lastFailedOperation=Verse.PatchOperationTest(Defs/ThingDef[defName = "ArchotechBase"])) failed
file: D:\Games\Steam\steamapps\common\RimWorld\Mods\MyMod\Patches\MedPatches.xml

And here is the modified code (I'm sure there's some mistakes in there). I commented out what I THINK is going on, and what some possible issues could be...

<li Class="PatchOperationTest">
<xpath>Defs/ThingDef[defName = "ArchotechBase"]</xpath>
</li>
<!-- So, the above should check if it exists (if the xpath is correct). This appears to be where the error is .... See my notes below the code. -->
<li Class="PatchOperationRemove">
<xpath>Defs/ThingDef[defName = "ArchotechBase"]</xpath>
<value>
<graphicData>
<texPath>Things/Item/BodyPart/Bionic2</texPath>
</graphicData>
</value>
</li>
<!-- and this should remove the texture from the parent. Right?  I don't want to remove any of the other information from ArchotechBase because it might be important. -->
<li Class="patchOperationReplace">
<xpath>Defs/ThingDef[defName = "ArchotechEar"]</xpath>
<value>
  <graphicData>
                             <texPath>Things/Item/BodyPart/ArchotechEar</texPath>
                           </graphicData>
</value>
</li>
<!-- I think, since the base texture is removed now, this code should replace the texture for the individual item? correct? -->


So, I guess the first question... is the xpath correct?  The <ThingDef Name="ArchotechBase" ParentName="BodyPartModBase" Abstract="True"> tags are located in a file called Items_BodyParts_ArchoVanilla.xml.  So, does that mean the "xpath" is correct or not (not sure how to determine this ... I just know all of the other ThingDefs are in here)
#14
Help / Replacing Textures for Prosthetics
April 15, 2021, 01:26:57 PM
I've been using the "Expanded Prosthetics and Organ Engineering" mod...
https://steamcommunity.com/sharedfiles/filedetails/?id=725956940

The mod shows a single graphic for all the prosthetics (a box image). I wanted to update the graphics with my own mod, so each prosthetics has their own graphic. I've been able to do this successfully for most of the images... but am having trouble with a few items...

See example here: http://www.amazingdg.com/_client/rimworld/med.jpg

I've replaced the images for many of the items (i.e. adv bionic leg, bionic ear, mutant leg, mutant arm, mutant eye, artificial clavicle). But, for some reason, I can't change the textures/images for any of the Archotech items (the microchip in the image above)...



Here is the code that I used for all of the other medical items (replacing the defName for each object), but it doesn't work for the archotech items.

<li Class="patchOperationAdd">
<success>Always</success>
<xpath>Defs/ThingDef[defName = "PegLeg"]</xpath>
<value>
<graphicData>
<texPath>Things/Item/BodyPart/PegLeg</texPath>
<graphicClass>Graphic_Single</graphicClass>
<drawSize>0.80</drawSize>
</graphicData>
</value>
</li>


I've also tried this code (and this didn't work either) ...

      <li Class="patchOperationReplace">
<success>Always</success>
<xpath>Defs/ThingDef[defName = "ArchotechEar"]/graphicData/texPath</xpath>
<value>
<texPath>Things/Item/BodyPart/ArchotechEar</texPath>
</value>
</li>


Any help?



I don't know XML too well... but I think (maybe) it might have to do with the "ParentName" ... Below is from the Mod, where they classify the group/parent, and designate the MAIN graphic. Then they designate the individual items...

<ThingDef Name="ArchotechBase" ParentName="BodyPartModBase" Abstract="True">
    <graphicData>
      <texPath>Things/Item/BodyPart/Bionic2</texPath>
      <graphicClass>Graphic_Single</graphicClass>
      <drawSize>0.90</drawSize>
    </graphicData>
    <thingCategories>
      <li>AdvancedProstheses</li>
    </thingCategories>
  </ThingDef>

  <ThingDef ParentName="ArchotechBase">
    <defName>ArchotechEye</defName>
    <label>archotech eye</label>
    <description>An artifical eye...</description>
    <techLevel>Archotech</techLevel>
    <thingSetMakerTags>
      <li>RewardSpecial</li>
    </thingSetMakerTags>
    <statBases>
      <MarketValue>3100</MarketValue>
      <Mass>0.3</Mass>
    </statBases>
  </ThingDef>
#15
I am trying to replace some textures for the stones/rocks (ex: RockLowA.png). I actually replaced the texture... but in the game,  SOME of the rocks were replaced (new texture), but others weren't (they used the old texture). I used letters a-f.

Textures\Things\Item\Chunk\ChunkStone\_RockLowA.png
Textures\Things\Item\Chunk\ChunkStone\_RockLowB.png
Textures\Things\Item\Chunk\ChunkStone\_RockLowC.png
Textures\Things\Item\Chunk\ChunkStone\_RockLowD.png
Textures\Things\Item\Chunk\ChunkStone\_RockLowE.png
Textures\Things\Item\Chunk\ChunkStone\_RockLowF.png

Note: The CORE ART says that these names should be "RockLowA" ... and not "_RockLowA" ... but "RockLowA" gives me an error message.

Let me know. Thanks!