def compare_materials(self, material):
""" Compare two WoW material properties """
get_attributes = operator.attrgetter(
'Shader', 'TerrainType', 'BlendingMode',
'Texture1', 'EmissiveColor', 'Flags',
'Texture2', 'DiffColor')
mat1 = get_attributes(material.WowMaterial)
for material2, index in self.material_lookup.items():
if mat1 == get_attributes(material2.WowMaterial):
return index
return None
wmo_file.py 文件源码
python
阅读 30
收藏 0
点赞 0
评论 0
评论列表
文章目录