Is there a way to set the material element slot order?

I have two static meshes that were imported from Maya with the same materials assigned to them. However the material element ordering is different between the two. Element 2 and element 4 are flipped in the static mesh on the right in the pic I’m attaching.

This is a problem because I’m using both static meshes in a BP where one part of my BP lets the user assign materials that the static meshes use. So with one having a different element order, it looks wrong.

Is there a way to fix this?

2 Likes

Been searching all over and haven’t been able to find a solution so far.

That wont work for me in this case. I need to be able to make sure the element ordering for my meshes are the same.

Something in Maya is deciding the ordering and I’m not sure what.

So I found a solution that works. This problem seems to be obscure enough that not many of us actually run into it.

Haha, no I’m not gonna leave you hanging on the solution.

Epics answer to this problem is set material by name, this lets your BP assign the correct material to your mesh regardless of the material element order. And this works fine, if your BP only uses one set of materials for everything.

(This is for Maya users as I use Maya)

If you really need to set the material element order for you meshes group and have them all have the same order.

You need to separate your mesh by material, so each part only has one material assigned.
Group your parts together in the Outliner and then arrange the parts in the order that you need. Export it.
On import to UE4 tell it to combine meshes on import and now you will have a mesh with the material element order that you set in Maya.

231339-pic1.jpg

2 Likes

If you are already using them in a BP you could just set the material for whichever ID you like for each mesh in the construction script.

This is an old post - so perhaps this udpated fix is already known - but thought I’d share.

If you want to force a material order in Maya so that they import in that same order in UE4 - use this naming convention:

  • Use a prefix of “M_” and a suffix of “_skin00” or “_skin01” etc.
    Examples:
  • M_MaterialName_skin00
  • M_MaterialName_skin01
  • M_MaterialName_skin02
2 Likes

Old post, but this could help Maya users, it is a pyton plug-in to reorder materials.

1 Like

Having the prefix and surffix doesn’t do anything when you bring it in unreal. I wish unreal would just let us reorder it in the mesh
image