made the first exported file start at index 0 instead of 1
This commit is contained in:
@@ -25,7 +25,7 @@ for index, node in enumerate(active_document.topLevelNodes()):
|
||||
InfoObject().setProperty("transparencyFillcolor", [0,0,0])
|
||||
|
||||
base_name = os.path.splitext(os.path.basename(active_document.fileName()))[0]
|
||||
file_name = f"{base_name}_{index:04}_{node.name()}.png"
|
||||
file_name = f"{base_name}_{index-1:04}_{node.name()}.png"
|
||||
path = os.path.join(export_directory, file_name)
|
||||
node.save(path, active_document.resolution(), active_document.resolution(), InfoObject())
|
||||
print("Exported: ", file_name, "\n")
|
||||
|
||||
Reference in New Issue
Block a user