diff options
-rw-r--r-- | texture_paint_layer_manager.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/texture_paint_layer_manager.py b/texture_paint_layer_manager.py index 8552601c..88d3af26 100644 --- a/texture_paint_layer_manager.py +++ b/texture_paint_layer_manager.py @@ -346,16 +346,17 @@ def main(context,tn): m_id = ob.active_material_index if img: - for f in me.faces: + for f in me.polygons: if f.material_index == m_id: - uvtex[f.index].select_uv uvtex[f.index].image = img + print('if') else: - for f in me.faces: + for f in me.polygons: if f.material_index == m_id: uvtex[f.index].image = None + print('else') me.update() @@ -630,4 +631,4 @@ def unregister(): bpy.utils.unregister_module(__name__) if __name__ == "__main__": - register() + register()
\ No newline at end of file |