updated organization script

This commit is contained in:
Vysyr committed 2026-09-04 23:46:21 +02:00
1 parent c448623471
commit 7977fa254c
2 files changed
+5 -7

No files matched your search

Binary file not shown.
+5 -7
View File
@@ -1,14 +1,12 @@
import re, unreal
FOLDERS = {
"material": "Materials",
"player": "Characters/Player",
"enemy": "Characters/Enemy",
"particle": "Effects",
}
CLASS_FOLDERS = {
"World": "Maps",
"LevelSequence": "Sequences",
"Material": "Materials",
"MaterialInstanceConstant": "Materials",
"NiagaraSystem": "Effects",
"Blueprint": "Blueprints",
}
PREFIXES = {
"World": "",
@@ -38,7 +36,7 @@ for path in lib.list_assets("/Game", recursive=True):
name = re.sub(r"^(" + "|".join(p for p in PREFIXES.values() if p) + ")", "", name)
name = PREFIXES.get(cls, "") + name
folder = CLASS_FOLDERS.get(cls) or next((f for k, f in FOLDERS.items() if k in name.lower()), "Misc")
folder = FOLDERS.get(cls, "Misc")
dest = f"/Game/{folder}/{name}"
if path != dest:
lib.rename_asset(path, dest)