• Hi Guest!

    We are extremely excited to announce the release of our first Beta for VaM2, the next generation of Virt-A-Mate which is currently in development.
    To participate in the Beta, a subscription to the Entertainer or Creator Tier is required. Once subscribed, download instructions can be found here.

    Click here for information and guides regarding the VaM2 beta. Join our Discord server for more announcements and community discussion about VaM2.
Resource icon

Plugins + Scripts Appearance Preset Extractor

Download [<1 MB]
This tool automatically export presets from existing scenes and collects them in an "extracted" folder under presets. The presets will use the thumbnail for the source scene.

This is for turning "Looks" that people package as a junk scene, instead of properly distributing appearance presets, into something usable, so you can safely hide all that garbage in your scene browser.

The behavior is comparable to ZFHX's "Var Looks Scanner plugin", although the implementation is entirely different.

This is a standalone python script, not an in-program plugin. This requires python3 to be installed and working already, and optionally uses the tqdm package if installed.

Usage Instructions:

  1. - Save the file to your root directory -- the same folder as AddonPackages -- as a .py python script
  2. - Run python3 extract_appearance.py {files}..., where {files}is a list of scene .json files or .var archives, or globs to those files.
    1. For instance
      python3 extract_appearance.py AddonPackages/Anon.SceneName.1.var to extract appearance presets from one scene,
      python3 extract_appearance.py "AddonPackages/Anon*.var" to extract all scenes by Anon, or
      python3 extract_appearance.py "Saves/scene/*.json" "AddonPackages/*.var" to extract absolutely everything.

If this script finds an obviously broken file, it will rename it with the .invalid extension to prevent further errors.

Future todos:
- Options to extract other presets (clothing) from scenes
- Enhancements to argparse, logging, output options, etc
- A better system for ignoring ephemeral morphs like expressions and impacts. Currently this uses a very short blacklist in order to avoid spamming the folder with obvious duplicates, but it's not very sophisticated.

Share this resource

Latest updates

  1. 2.1

    Disable ensure_ascii
  2. 2.0 - New outfit extractor

    Refactors the code and adds an optional outfit extractor. Use with --outfit to enable.
  3. 1.3.2 Hotfix

    Improved duplicate detection and appearance simplification logic Internal "noclobber" behaviour...

Latest reviews

Positive
Version: 2.1
Posted:
I've found this script to be very useful! Especially since adding the feature to extract Clothing presets in addition to Appearance presets. I wrote a script which automatically transfers the extracted files to creator subfolders based on matching creator name (subfolder name) within the file names. I've found this to be a very useful compliment to the script.
Upvote 0
Positive
Version: 2.1
Posted:
For any other python noobs out there like me. It took me way too long to figure out.
I thought I had the wrong python version or something. I had a saved file from within VAM that was instantly breaking the script.
download python 3.13
right click in your directory open up terminal
type python3
then throw in the command. Cheers!
Upvote 0
Positive
Version: 2.1
Posted:
After extracting about 1000 presets from the scenes, it seems that this script handles only around 40% of them. In 40% of cases it does not transfer character morphs from json to vap file. It does not matter if there are 1 or 3 characters in the scene. I wish it would be corrected.
EDIT: I found out that if I delete 4 lines - 195 to 199, all morphs are transfered successfully to the VAP file. strange. Could the author look what happens?
cartitolaire
cartitolaire
Can you send an example of a problematic scene? Those lines are meant to filter out properties that are irrelevant to the pose, which helps with filesizes and deduplication, but it could somehow be catching something significant.
Upvote 1
Positive
Version: 2.1
Posted:
Question: If you run it twice will it skip ones already created?
Upvote 1
Positive
Version: 2.1
Posted:
Extra points for properly shaming look creators who don't package appearance presets in their .vars
Upvote 1
Positive
Version: 1.3.2
Posted:
I have no basic python knowledge, but I did it using your explanation and chatgpt

It works well and has been very successful

thank you so much bro!
Upvote 0
Positive
Version: 1.3.2
Posted:
It did a good job, just kept crashing with any version of ascorad's Heads Will Roll scene. Suggest to look into why it did that.
cartitolaire
cartitolaire
Crashing? Hanging, or crashing with a stacktrace?
Upvote 0
Positive
Version: 1.3
Posted:
Thank you so much, i hate all those "scenes" that only shows the look and nothing more.
cartitolaire
cartitolaire
I hate that pattern so much.
Upvote 1
Positive
Version: 1.3
Posted:
Amazing
Upvote 0
Positive
Version: 1.2
Posted:
Ok, call me impressed. This script plowed through 1300 vars in a few minutes. It's sooo much faster than "Var Looks Scanner plugin". Thank you for this incredible timesaver. You might consider compiling this with cx_freeze and releasing it as an executable. Kudos!
Upvote 0
Back
Top Bottom