Textures - Stellar-Blade-Modding-Team/Stellar-Blade-Modding-Guide GitHub Wiki
Overview
Textures plays a big role for in game meshes. It can be from any custom models or some edits with the game texture you try to import back to Stellar Blade. It's also for in game UI mods since a lot UI and background papers are basically textures. We will cover details of how to covert and import it to UE with information of each texture types.
Gratefully appreciate supports by Modder Minervha.
Texture Types
In this part we will be mainly scripting description of different types of character model textures that's been used in the game. It will be needed for custom texture import and editing in Stellar Blade.
• Body Mesh
Base Color Map
*Suffix example EVE_Costume_Temp_Inner_Skin_A
*Suffix example CH_P_EVE_09_Skin_D
It's often been used for diffuse map. This type of texture is what you can directly know if it's for which models from the preview of it such as skins and suits.
There are multiples ways to name base color texture in this game, A can stand for Albedo, looks like devs didn't agree each other on how to name base color texture since we have _A and _D
Normal Map
*Suffix example EVE_Costume_Temp_Inner_Skin_N
It is used to add details on model without using more polygons. This type of map often has a preview of purple. It often uses only red and green channel, the blue one isn't used, it's fully white (so 100% blue)
ORM Map
*Suffix example EVE_Costume_Temp_Inner_Suit_ORM
Game used multiple layered mask that contents different type of maps in it's RGBA layers.
Red channel for ambient occliusion, green channel for roughness, and blue channel for metallic.
Emissive Map
*Suffix example EVE_Costume_Temp_Inner_Suit_E
It is used for emissive effect on model. Strength of the effect can be adjusted with its own or in Material Instance.
DMSE Map
*Suffix example CH_P_EVE_BB_V01_DMSE
DetailMask Map
*Suffix example CH_P_EVE_09_Body_DetailMask
It uses RGBA channels as mask to color different areas (don't know for what purpose yet). It uses alpha to define the areas but not the colors.
• Head Mesh
NCSE Map
*Suffix example CH_P_EVE_Head_NCSE
ORSS Map
*Suffix example CH_P_EVE_Head_ORSS
O = AO R = Roughness S = Specular S = Subsurface Scattering (SSS)
Red channel for Ambient Occlusion, Green channel for Roughness, Blue channel for Specular and Alpha channel for Subsurface Scattering.
SSSAO Map
*Suffix example Tex_P_EVE_Head_SSSAO
Red = Ambient Occlusion, Green = Subsurface Scattering and Blue = Unknown yet
SSS Map
*Suffix example Tex_P_EVE_Teeth_SSS
Probably Subsurface Scattering mask.
Specular Map
*Suffix example Tex_P_EVE_RE_Head_S
C Map
*Suffix example Tex_P_EVE_Head_C
O Map
*Suffix example Tex_P_EVE_eyebrow_O
Opacity map. Only full black or full white values, cannot be grey/semi-transparent.
• Hair Mesh
Alpha Map
*Suffix example PonyTail_Alpha
Height Map
*Suffix example PonyTail_Height
CH_HR Map
*Suffix example CH_HR_Ponytail
This is note a type of map, but "CH" for character, "HR" for hair, so it's really specific to hairs. There are many texture without label for specific materials.
Red = opacity mask (full black and white values, no grey/semi-transparent), Green and Blue probably for color variation (still TBD) and Alpha channel for opacity (can be semi-transparent)
• Weapon
M map
*Suffix example CH_W_Sword_02_M
Similar to ORM map with Red channel = Ambient Occlusion ? (TBD), Green = Roughness and Blue = Metallic
Mask map
*Suffix example CH_W_Sword_02_Mask
For weapon vfx.
Notes: More to be added.
Previewing and Exporting
We will need FModel for preview and export textures. You can often found it in "Textures" subfolder under each suit/character folder.
*example location: Art/Character/PC/CH_P_EVE_Head/Textures
Instruction details for extraction with fmodel can be found in Extraction Tips
You can preview texture in app by simply clicking on the texture.uasset. There you can see the preview image of asset in the main output window.
*example Tex_P_EVE_Head_A
If a texture isn't located under the same ID's of the model, It could be a shared texture that been located in a different subfolder under another ID's. Click the model.uasset itself in app and find where the texture located in the output window. Example in Model Preview
You can extract all game textures in different format with FModel. In the end UE will convert them into .dds with BC/DXT compression. However .jpg is the least recommended.
Converting to TGA
Your custom textures or extracted game textures might not comes as TGA format by default.
It's not necessary to import textures as TGA in UE, You can import in whatever you want, aslong as the image format corresponding to your needs (.jpg can't contain alpha channel) but .png will do the job. It doesn't matter because UE will convert all the texture into .dds with specific format compression (DXT1/3/5 accordingly to the need). But here we just do TGA as example for learning how to convert texture formats.
We will use Photoshop as example since its the most popular image editing app. You can also build your own with substance painter but we can cover that part later.
• If you are editing exported texture asset from the game :
After texture extraction, simply open the texture with Photoshop and make your edits then save it back. Make sure to do that with a copy in a new location on your disk.
Click file >Save as
Select targa(*TGA) in Save as type >Save
• For custom model texture :
You can rename your custom texture to what the targeted original game texture's name is upon saving.
*example EVE_Costume_Temp_Inner_Skin_A is the one await for replacement for your custom model,
Copy (Ctrl+C) the name from this texture >Paste (Ctrl+V) it to your custom texture which corresponded to it's texture type
Importing to UE
Before you import anything in UE, you need to build the folder structure in UE that corresponded to what you saw in fmodel for the texture you replacing. Names of sub folders in UE must be identical as the game has or it won't work.
*example CH_P_EVE_09_Map01_D
Right Click on default folder in UE> Create folder output in UE following game file's folder structure
Copy (Ctrl+C) the name of folder or write it yourself> Click on folders name in UE and Paste (Ctrl+V)
Heres an example of the Uproject output from Model document.
There are two different ways you can import your textures in UE.
• Method A: Raw import with default setting
Simply drag your renamed custom texture and drop in UE and manually change the setting yourself. Alternatively you can rename imported texture in UE as well.
• Method B: Reimport with saved setting
Drag and drop the original in game texture into the correct sub folder it belongs to in UE. Save your project. Upon replacing the original texture with your custom/modified game texture that contents the same name, simply move your texture to where the previously imported original texture located on your disk and overwrite.
Then Go back to UE window
Right click on the texture > Reimport
This way UE will have option to keep the previous imported texture setting for you. Alternatively you can have your edited texture to be saved in the same location on your disk so you don't have to find it and drop back to UE every time you done new texture editing with support of the "reimport" feature.
At last don't forget to save in UE.
Texture Import Setting
Fmodel are informative, explain a bit where to look to know what parameters to set in UE, and UE screens are where those parameters are. On fmodel screen, we first check what texture is it, D for diffuse, N for normal etc... then we check what format compression it uses. Once imported we have to match settings in UE.
• Base Color map
Base color maps will end by “_D” (for diffuse) or “_A” (for albedo). There is no reason for such inconsistent nomenclature, but it will often be the case.
Import base color in UE is simple, there isn’t any particular parameter, just drag and drop the file in UE (in the correct filepath with the right name) and that’s it. Be sure sRGB is checked and the compression profile is set to “Default” as shown on the screen underneath. This should be the case by default.
On the screenshot here we can see the sRGB is well checked and “Compression Settings” is on “Default”.
You should also set the texture group correctly.
Level of detail> Texture Group> Change it to fit your mod
For character texture it should be set to "Character" instead of "World". This improves the texture and how the mips are generated and optimizes it for characters (objects that are usually always close to the screen). This rule applies to all the related textures such as CharacterNormalmap, CharacterSpecular respectively.
If you're modding a sword then texture group should be set to the "weapon". Weapons usually are already quite small on the screen compared to the character so higher compression usually doesn't make a difference.
For other static geometry objects those texture group should be set to the "world" in UE. Textures in the "world" texture groups are usually compressed more aggressively because these objects are considered to always be far away from the camera and small on the screen.
• Normal map
Normal maps will end with “_N”. This map contains height data, it will give an illusion of depth by deviating light. This map only uses 2 channels, the Red and Green ones, the blue is not used. Most of the time blue will be 100% that’s why we see normal maps purple, sometimes it’s 0% that's why it can also be seen yellow in certain engines.
Normal maps can be inverted, because OpenGL and DirectX read the green channel differently. UE uses DirectX. So if your normal map has been made for OpenGL engines, you can check “Flip green channel” in the advanced tab. You can open the advanced tab with the small down arrow under the “sRGB” box.
99% of the time Unreal understands well the imported texture is a normal map and will automatically change the settings, but in the case it does not, you can change it by yourself. Set the “Compression Settings” to “Normalmap”. It will compress the texture in BC5 which is a compression type specific for normal maps that doesn’t store the blue channel (since it doesn’t contain any data we need). This compression setting will turn off sRGB automatically.
Note: I’ve made a mistake here in image, Normalmap are stored in BC5 not DXT5
• ORM map
ORM stands for Ambient Occlusion, Roughness and Metallic and will end by “_ORM”. Each map is contained in the 3 channels of the RGB. So the red channel will store the ambient occlusion data, green channel roughness and blue channel metallic.
This type of texture will require a small extra step in UE. Once imported in UE, uncheck sRGB option, if you don’t do that it shouldn’t break your mod and the game will start, but the data won’t be read well.
Its gonna be more advanced to explain why we have to turn off this option. but long story short, these maps are not colors we’ll see with our eyes, the game reads each pixel as a numeric value between 0 and 1, and to do so, we have to tell the engine to not read this map like a color. For advanced users, you should be able to look for color space workflow in 3D.
• ORSS map
Stellar Blade also uses “_ORSS” maps, they are similar to ORM maps but used for skin material. As for ORM maps, O stands for Ambient Occlusion stored in Red channel, R for Roughness in Green channel, however the last 2 “S” stand for Specular in the Blue channel and Subsurface Scattering (also known as SSS) in the Alpha channel.
Subsurface Scattering simulates how light penetrates a surface (like how light goes through our skin on thin areas). See the illustration below.
Inspect Texture info
In FModel you can check what compression type a texture uses, and if sRGB is on or off.
When double clicking on a texture.uasset file, you will see those informations as shown on the following screenshots.
*example CH_P_EVE_09_MAP01_D
Some diffuse/albedo maps use DXT1 compression type, some others use DXT5. DXT5 allows better overall quality and a gradient alpha channel, which means it can be semi-transparent, while DXT1 alpha pixels are white or black (cannot be gray).
*example CH_P_EVE_09_MAP02_MASK
*example CH_P_EVE_09_MAP01_N
*example CH_P_EVE_09_MAP02_ORM_02
For in game UI
Some in game UI are stored as textures in game files. You can follow the same instruction above when trying to replace it. Just make sure you found the texture.uasset in the right filepath and import it to UE.
*example Keylcon_DualSense_Gamepad_FaceButtom_Top
Find the corresponded texture.uasset in Fmodel and export > Convert to TGA format
Go back to previous step above for texture editing and importing to UE.
Next we will move on to the step of Packaging Mods