PackageBuilder doesn't convert textures

SDK Version: 0.9.2

Frequency: Consistently

Severity: High

Bug description:
Textures are not getting converted alongside an “ArtProj” (model libaries) anymore although this is still described in the SDK:

I have read here (MSFS2024 Texture XMLs not auto-generating after building project) that this is intentional but for the sake of it I can’t figure out why and what would be the new workflows. The previous workflow was pretty straightforward as packagebuilder checked the textures alongside converting the models so the risk of corrupted/missing textures was minimized.

Update: Looking at the samples I have noticed that the correct entry for a modellib nowadays seems to be

ModelLib

…though that doesn’t force texture creation neither (and type “ModelLib” isn’t documented in the SDK).

Fyi

ModelLib is documented here

https://docs.flightsimulator.com/msfs2024/html/2_DevMode/Project_Editor/Asset_Types.htm

ArtProj was already intended to be used for legacy only in 2020 docu
https://docs.flightsimulator.com/html/Developer_Mode/Project_Editor/Asset_Types.htm?rhhlterm=artproj&rhsearch=ArtProj

Looks like I missed that one. So we have to manually convert textures alongside the models again like in the old FSX days? One one the huge benefits of the previous setup was that the textures were converted and checked “on the fly” and also always automatically updated on a new build when something changed.

However I can’t get Texture tool to work or I’m just unable to understand what I’m doing wrong:

  1. Adding a single texture by “Add Textures” results in:

  2. Trying to add a texture path results in:

I’m a bit confused here:
For Simobjects, DevMode creates the XML files manually as can be seen here:

For SceneryObjects this doesn’t happen and as long as the TextureTool isn’t working we need to create an XML file for each individual texture manually?

Hello,

Here is the documentation that explains how to use the “Texture Tool” :
https://docs.flightsimulator.com/msfs2024/html/3_Models_And_Textures/Plugins/3DS_Max_Plugin/Texture_Tool.htm

In your case, it does not work because you can’t simply add a new texture and export it’s xml if the texture is not referenced in any material of you 3dsmax scene.

image

You can only add a texture if it does not already exist in the scene but another texture with the same name is referenced in the scene using the same name as the one being added. This is the only way to know what your texture is used for.

You should either update your package to get your texture xmls if you just want to have you actual models in MSFS2024 or if you want to change them, you will have to re-export all of your models updating your materials to get your new compatible MSFS2024 models.

Thank you

Thank you for your detailed reply @Yasmine !
Can you elaborate how “update your package” works? I assume it’s supposed to work the same way as with simobjects. When I load the package (that includes both simobjects and a modellibrary), DevMode only asks me to update the simobjects, but not the modellibrary objects/textures.

Beyond that I still have a hard time to understand what the TextureTool is supposed to be for. You mention that I can’t just add a texture if it’s not referenced in a material of my currently open 3DS scene. Then you mention that I can only add it if it does not already exist in the scene… I’m confused, sorry…

In addition I tried to make a normal export using MultiExporter with texture export activated and “Generate Texture Lib” ticked and get the following errors as an example:

== TEXTURE LIB EXPORT ================================================================================================================
[TEXTURELIB][ERROR] An XML couldn't be created for these textures : 

[TEXTURELIB] XML for Casey_Ballonstart01.png couldn't be created. Check if the texture exists in the project. It could be converted to another format while writing.

[TEXTURELIB] XML for Casey_Ballonstart01_spec.png couldn't be created. Check if the texture exists in the project. It could be converted to another format while writing.

[TEXTURELIB] XML for Casey_Ballonstart01_normal.png couldn't be created. Check if the texture exists in the project. It could be converted to another format while writing.

[TEXTURELIB] XML for Casey_Ballonstart01_LM.png couldn't be created. Check if the texture exists in the project. It could be converted to another format while writing.

== END OF EXPORT PROCESS ============================================================================================================

The textures are referenced in the MSFS2024 materials, display fine in 3DS Max. BUT they are TIF files as this is the only file format that works fine with the SDK and supports layering etc. so we don’t need yet another set of source textures. In the previous SDK these have simply been converted to PNG when exporting et voila.

Hello,

The babylon exporter does convert “tif” format to “png”.

For now, in your case, i would recommand :

  • Not exporting the textures with the gltf (you will have to uncheck the “write textures” option in the export settings)
  • Re-export your model with the 'generate texturelib" option checked, you’ll get your xmls generated beside your original textures
  • Copy them where you want in your package source.

Hello!

Forgive me ignorance if I’m not seeing the obvious here but from an addon developer’s perspective there are quite some inconsistencies here.
Am I right to assume that your recommendation would be temporary until the SDK is finalized? Because if not that would mean the following:

  1. The DevMode creates the applicable XML files automatically for outdated simobjects, but not for scenery objects.
  2. It is quite an undertaking to open and review all models from a project in 3DS Max/Blender + convert to the new materials while all that is required - with the MSFS2024 materials having almost the same structure - are the XML files, which could be easily created based on information already existing in the GTLF files (similarly to how it works with the simobjects). The previous MSFS2020 seems to do exactly that: Determine the optimal texture types based based on what the GLTF file calls and converting them. Just without the intermediary XML file (which should be easy to create automatically following the same procedure as in MSFS2020 SDK when needed?).
  3. Your recommendation above tells us to generate a texture lib but not to convert the textures themselves along with the model export? What would be the intended workflow for texture conversion then?
1 Like

Hello,

Unfortunately this is by design, you will need to re-export your 2020 models if you want to change them or add new textures. The xmls are needed to get your 2024 packages to get build, otherwise your new textures will not be detected.

Thank you