1
0
mirror of https://github.com/DarklightGames/io_scene_psk_psa.git synced 2024-11-24 06:50:13 +01:00

Fixed a bug with materials in PSK export

This commit is contained in:
Colin Basnett 2024-04-21 00:55:58 -07:00
parent 06b1dd10a8
commit c51a8f21df

View File

@ -29,9 +29,9 @@ def populate_material_list(mesh_objects, material_list):
if material is None: if material is None:
message = bpy.app.translations.pgettext_iface('Material slot cannot be empty (index {index})') message = bpy.app.translations.pgettext_iface('Material slot cannot be empty (index {index})')
raise RuntimeError(message.format(index=i)) raise RuntimeError(message.format(index=i))
if material.name not in materials: if material not in materials:
materials.append(material) materials.append(material)
for index, material in enumerate(materials): for index, material in enumerate(materials):
m = material_list.add() m = material_list.add()
m.material = material m.material = material