Hi there! You are currently browsing as a guest. Why not create an account? Then you get less ads, can thank creators, post feedback, keep a list of your favourites, and more!
Inventor
Original Poster
#1 Old 22nd Nov 2014 at 10:19 AM Last edited by Arsil : 27th Nov 2014 at 10:48 AM.
Default Editing/deleting presets with S3PE
Hello,
This is my first post in this section, please take good care of me.

I'm not masochist, if I could use TSRW or Texture Twicker I'll do it,
but for some reason I can't. So I'd like to learn how to delete and
edit presets just using S3PE.

Example 1: I cloned a rug with three presets but I only want one for my object.
Example 2: I want to change the colors of the channels of a preset (not sure if
I'm using the right terms).

I'm analyzing packages to get an idea how that works, but that could take me
a lot of time, assuming I can do it. Right now I got the idea (probably wrong)
that the first or default preset is defined in the OBJD itself and, if there are
others, they are just mentioned/referred in the OBJD but defined in a XML.
Does any of that makes sense?

Using "Grid" on the OBJD and messing with the "Materials" collection may
have something to do with it?

In what format are the colors defined? In a quick attempt to figure that out it seems
like they are defined as floats with a value from 0 to 1, can I can translate that using
the more common 0..255 scale?

Thanks for your attention and sorry for my poor English, bye,
Arsil.

EDIT
It seems like the OBJD resource contains almost all data but also references _XMLs for... not sure for what.

I think I guessed correctly, at least partially, about the "Materials" block/collection containing the presets and their colors.

Colors are defined in a ARGB hex format (if that's a thing), for example 0xFF70A9F0 for a cyan-ish color.

EDIT2
Changing the colors from the OBJD doesn't work, maybe I'm not editing
the right values or maybe they're overridden by some XML settings.
EDIT3
Nope, it actually worked.

YetAnotherEditButThisIsTheLastOneIPromise
About deleting and adding presets, you can do that too using this method,
but be careful to also delete resources associated with the preset[s] you
are deleting and take care of not deleting those shared by the preset you
want to keep. If you can, of course, use the tools that do that for you.
Advertisement
Inventor
Original Poster
#2 Old 28th Nov 2014 at 10:10 PM Last edited by Arsil : 1st Dec 2014 at 6:21 PM.
I cloned the food register of WA. I converted and simplified a free to use and modify 3d model found in a online
database and used it as mesh for my object. I changed the rgb mask, base texture (multiplier?), specular and
overlay (keyboard and display of the register).

I tried the object in game, placed it, seen the new mesh but it was still using the mask and textures of the
cloned register (all messed up because the mesh was different). I checked the object presets (it has only
one) using Grid on the OBJD but the "Materials" block was empty. Then I noticed the XML that defines
the preset's values (is it linked to the model just by having the same instance id?), but all its tags pointed
to TGIs of the resources of the original object. I changed those values to point to the resources in my
package and I also changed the colours' codes.

I tried the object in game again. It was using my RGB mask and my textures but the colours didn't match
(they still looked like those of the original register but altered by the different texture). Then I noticed that
using Create A STyle on the object, without even changing any colour but just updating the rendering (?)
of the object, it assumed the colours I defined in the XML. See screenshot.
The image is flipped for presentation's sake [As you can see the UV Mapping is flawed, but that can wait].


So, my problem is: how to use directly my colouring's settings without using CAST? Where do the "wrong"
colours come from? What resource should I inspect? I searched the IID of the _XML of the original register,
but that doesn't seem to be referenced by any resource in my package.

Another thing I noticed is that when I select the object from the catalog, its rotating 3d preview displays the
right colours, while the thumbnail and the preset (?) display the wrong ones. See screenshot.

Anyone has ever faced a problem like this? Any suggestion?

EDIT
I found the sneaky colours, they were hiding in the 2 TXTC.
I'm removing the screen shots since they are not longer needed.
Inventor
Original Poster
#3 Old 2nd Dec 2014 at 10:25 AM
Very well, I'm glad to say that I was able to fix all the [visible] issues of the cash register
(ehm... I just learned that the specular texture is not transparent/empty...).

When I recompile the main LOD with S3ObjTool I get the error message "UV scaling
overflow for group0" (the floor/drop shadow mesh), but it seems that the object is fine
(I get that because I passed from 256*256 to 512*512 for the size of the textures?).

One last question about the overlay texture (focus on the keyboards): [the texture looks fine normally, only with that camera angle is blurred.]
Screenshots
Back to top