How can i change the textures ?

Started by eloxia, June 01, 2016, 12:20:15 PM

Previous topic - Next topic

eloxia

Hello everyone. 1st i've already got the new textures for building furniture or wall etc. but i dont know how can change these? so i wait your helps  :)
For example i attached the picture, for new brew table. i want change this one with orginal.

[attachment deleted by admin - too old]

joaonunes

#1
Quote from: eloxia on June 01, 2016, 12:20:15 PM
Hello everyone. 1st i've already got the new textures for building furniture or wall etc. but i dont know how can change these? so i wait your helps  :)
For example i attached the picture, for new brew table. i want change this one with orginal.

Somewhere in this forum there is a zip with all the basic texture directories, and I think it includes the table textures too.

Try to find that file and look inside it for the directory of the table you want to replace, then you just need to copy the directory of the file and create a mod that adds a texture with the same name and directory.

This may not be the prettiest way of replacing a texture but it works...


The said file should be somewhere in the Help thread or somewhere else related to game's resources, it should be pinned anyways

EDIT: yeah, literally the first pinned post in this thread...
https://ludeon.com/forums/index.php?topic=2325.0
Do you want your colonists to look manlier?
Get a free mustache sample here!

1000101

Yes, all you need to do is have the proper /Textures/ directory structure and the game will use loose files in preference over the assets files.
(2*b)||!(2*b) - That is the question.
There are 10 kinds of people in this world - those that understand binary and those that don't.

Powered By

Silerra

I also tried to change the texture. But it doesn't work for me somehow.
These things have already done:
- A new mod folder named as MyMod
- In this folder contains a folder "About" with file About.xml
- And a another folder "Textures"
I tried to change the picture PassionMajorGray and PassionMinorGray. I placed the PNGs in /Textures/UI/Icons/ with appropriate filenames.

What I doing wrong?

Master Bucketsmith

Quote from: Silerra on August 22, 2016, 10:22:39 PM
I also tried to change the texture. But it doesn't work for me somehow.
These things have already done:
- A new mod folder named as MyMod
- In this folder contains a folder "About" with file About.xml
- And a another folder "Textures"
I tried to change the picture PassionMajorGray and PassionMinorGray. I placed the PNGs in /Textures/UI/Icons/ with appropriate filenames.

What I doing wrong?

Copy the part with the texPath and we might see something.

Silerra

What's meant by "texPath"?
Where the file is stored? Here the full path "F:\Spiele\RimWorld1249Win\Mods\Silerra\Textures\UI\Icons\PassionMajorGray.png"

By the way, I have found that my changes in "Textures\UI\Designators" are accepted.

Master Bucketsmith

#6
No, you need an XML file to tell the game to use your alternative texture in the ThingDef for the brewery.
It's inside <texPath></texPath> tags, which are inside <graphicData></graphicData> tags.

EDIT: Sorry, seems I was reading over some bits in the thread. The brewery texture is not all that you want to change, I get?
And E said as long as you have the right folder structure and the exact filenames it should pick up, so if your only goal is to replace vanilla textures, you don't need to edit any XMLs, I guess.

Silerra

Well, I just want only to replace the vanilla textures. But probably I don't know all current paths. And I don't know how to integrate textures via XML. So far, I not yet discover how to this XML files works.

Master Bucketsmith

You weren't asking, but perhaps the autodocumentation can help you with the filepaths.

Silerra

I couldn't find an entry about "PassionMajorGray" in autodocumentation. But nevertheless, I already know the matching texture path.
Well, this doesn't work via XML file like this:

<?xml version="1.0" encoding="utf-8" ?>
<ThingDefs>
  <ThingDef Name="" ParentName="">
    <graphicData>
      <texPath>UI/Icons/PassionMajorGray</texPath>
      <graphicClass>Graphic_Single</graphicClass>
    </graphicData>
  </ThingDef>
</ThingDefs>


I think that not all images can be replaced on this way. Because some images are loaded before mod indexing.

nccvoyager

#10
I don't know how it works, but I found this post that may help find the path to specific textures:
https://ludeon.com/forums/index.php?topic=2325.msg255769#msg255769

Edit: Not pretty, but I opened the file in Notepad++, and found the paths.
Again, not pretty, nor easy to read, but it is there.

textures/ui/icons/passionminorgray
See attachment for a simple direct replacement mod example.
(It may not work as intended; don't have access to a computer I can test it with.)

[attachment deleted by admin due to age]

Silerra

Quote from: nccvoyager on October 24, 2016, 02:21:42 AM
...
textures/ui/icons/passionminorgray
See attachment for a simple direct replacement mod example.
(It may not work as intended; don't have access to a computer I can test it with.)

Oh, why suggest to me what I tried in August as a second? :-P

Quote from: Silerra on August 23, 2016, 01:15:13 PM
What's meant by "texPath"?
Where the file is stored? Here the full path "F:\Spiele\RimWorld1249Win\Mods\Silerra\Textures\UI\Icons\PassionMajorGray.png"

By the way, I have found that my changes in "Textures\UI\Designators" are accepted.

My first solution I had there already. However, this was to edit the "resources.assets" file for each update. Not pretty and especially too elaborate.

Currently I have a second solution. Here an existing class is simply integrated as a mod. Also not so pretty. But this way was easier to make this mod. (Look in my following zip.)
;-)

[attachment deleted by admin due to age]

nccvoyager

Ah, yeah, sorry. Didn't realize you had already tried it.
Also, doesn't work, I realize now that I actually tested it.
It does seem that there is no particularly "easy" method to changing the UI icons.

Though, perhaps you are on to something. :)
(I am unsure; haven't been doing too much modding in RimWorld at this time.)