Basic Material: exported materials are unnamed (no name copied from GLB)

When I set a 3D model’s material type to Basic Material, all materials end up with no name in Three.js (e.g. material.name is empty or undefined), so they all appear as “(unnamed)” in the runtime.

If I use Standard/Original Material for the same model, material names from the GLB (e.g. “Bark”, “Leaves”) are preserved correctly. Here’s the debug log for all material types.

Basic Material:

Standard Material:

Original Material:

So it looks like when GDevelop creates the Basic (unlit) materials, it doesn’t copy the original material names from the loaded GLB. That makes it hard to target specific materials (e.g. leaves vs trunk) by name when all materials are unnamed.

Is this by design, a bug, or an oversight on my end?

EDIT: macOS Tahoe 26.2, GDevelop version 5.6.253

Probably not something done on purpose - would be worth checking if this can be patched easily in the game engine.

Should be a matter of doing this: Fix Basic Material not preserving material names from GLB models by 4ian · Pull Request #8256 · 4ian/GDevelop · GitHub

(Not tested yet)

1 Like

Thanks for looking into this… hopefully that does it. I did have a version of the extension with my own lit material - basically a stripped down version of the MeshPhysicalMaterial - but that was kinda hacky, so I removed it :smiley:

@4ian hmm, I also just captured this - the material doesn’t seem to have seems to have transparency (as you can see in the debug output).

This has been fixed in the latest update!