12-20-2016, 11:47 PM
Well. Im starting with python to do some tools I need for fast animation creation.
I´ll share this little scripts.
Mostly of this script will be posted focused for Anim edition or "surrounders" and safe as much time as we can.
What you need? Python 3 (or 2) and Thonny. I recommend to use thonny for playing the script, is the way I will ever use until I changed it.
Automatic FileName Changer:
I´ll share this little scripts.
Mostly of this script will be posted focused for Anim edition or "surrounders" and safe as much time as we can.
What you need? Python 3 (or 2) and Thonny. I recommend to use thonny for playing the script, is the way I will ever use until I changed it.

Automatic FileName Changer:
Spoiler (Click to View)
Description: This script allow you to delete initial letters of each name in the same folder the script is saved (Thonny).
So usefull if you want to use .bmp taken from fiddler to make a new anim in with the .bmp to .vd convertor.
Notes:
-os.rename(filename, filename[12:]) This will erase the first 12 letters of name.
DONT FORGET TO CHANGE THIS NUMBER, You will need diferents numbers for differents file´s names.
- if filename.startswith("anim"): This lane ensure u only rename files from fiddler, and not any file in folder. Simple as fk.
Same but with Windows cmd/bat (by Kanibal)
So usefull if you want to use .bmp taken from fiddler to make a new anim in with the .bmp to .vd convertor.
Code:
import os
for filename in os.listdir("."):
if filename.startswith("anim"):
os.rename(filename, filename[12:])
-os.rename(filename, filename[12:]) This will erase the first 12 letters of name.
DONT FORGET TO CHANGE THIS NUMBER, You will need diferents numbers for differents file´s names.
- if filename.startswith("anim"): This lane ensure u only rename files from fiddler, and not any file in folder. Simple as fk.
Same but with Windows cmd/bat (by Kanibal)
Spoiler (Click to View)
Code:
setlocal enabledelayedexpansion
for %%F in (anim*) do (set "FN=%%F" & set "FN=!FN:~12!" & ren "%%F" "!FN!")
setlocal enabledelayedexpansion
for %%F in (anim*) do (set "FN=%%F" & set "FN=!FN:~12!" & ren "%%F" "!FN!")