Tool Others HTML Ren'Py YAC - Yet Another Cruncher (A Game Compactor) [V3.4] By Hhgg

  • Thread starter Deleted member 39699
  • Start date
  • Replies 0
  • Views 342

Deleted member 39699

You must be registered to see attachments


YAC is a Windows batch script file that helps to automate the use of certain command line tools, like cwebp.exe and ffmpeg.exe
YAC allows you to compress many different types of files, including pictures, music, and video in a quick and easy menu-driven way.

Use WEBP, OPUS, and VP9 to compress images, audio, and video. File size can be up to 90% smaller than original.
Original file extensions are preserved
Remove audio from videos (optional)
Extract .RPA files using UnRen
Reduce video resolution for smoother playback and even smaller file size (optional)
Quality is customizable with 3 presets: High, Medium, and Low.
You can adjust quality levels even more using the "custom" option.

Everything you need to use YAC is included in the YAC.7z file.
There are two ways to use YAC:

-METHOD ONE- "Generic"
This method can be used to compress pretty much ANY picture, music, or video file, but
make sure whatever you plan to play the files with supports .webp, .opus, and .webm files!

Extract entire YAC.7z file into a new(empty) folder.
Then, copy any files you want to compress into the "game" folder and run the YAC.bat file

This method is recommended for compressing RenPy games

Extract entire YAC.7z file into a RenPy game's root folder(the one with the game EXE file)
You may be asked to merge YAC's "game" folder with the one that already exists in the game's folder. Pick whichever you want.
Then, run the YAC.bat file

*Some games place their files into .rpa files, which are sort of like .zip files.*
*You MUST extract the .rpa files BEFORE you can compress a game!*
To extract .rpa files, simply run YAC and select the "UN" option after selecting quality level.

Backups are not made for you. I recommend you make a COPY of the game's folder FIRST.
Only delete the "copy" folder after you've made sure nothing went wrong.
You've been warned!


YAC features 4 quality presets. Ultra, High, Medium, And Low (Mobile)

This setting is best used with high quality source files like .PNG and High bitrate video.
If you are a game developer and wish to prepare your game for distribution while maintaining excellent quality, choose this setting.
File quality is virtually identical to original, but file size won't drop as much as other settings and compression time is longer.

This setting tries to maintain most of the original quality while still giving a decent amount of size savings.
This setting is for game developers who want to maintain quality but find the "Ultra" preset too large.
Final quality is generally very close to original.

This is the most balanced setting and is recommended for most situations.
File size will generally be reduced by a large amount while overall quality should still be quite good.
Lossy transparency compression is enabled with this setting.

This setting is recommended if you are trying to port a game from desktop to mobile(Android/iOS).
This setting will drop file sizes by a huge amount but quality will be noticeably reduced from original.
Lossy transparency compression is enabled with this setting.
*Optional* video resolution limiting is also available with this setting (explained below).

This setting is recommended for experienced users or special circumstances where the normal presets don't work well.
You can set Image, Audio, and Video quality independently and can enable resolution limiting if you want.
Quality settings are on a scale of 10-100, with 100 being the best quality(even better than the "High" preset).
Setting everything to 100 may actually give you bigger files than what you started with, so be careful.

YAC can limit the resolution of videos(YAC does not upscale).
This is useful when porting to mobile because 1080p video generates more heat and wastes battery life on phones.
The VP9 video format used by YAC is very hard on the CPU and older phones may overheat/slow down trying to play 1080p video.
540p is what I recommend to use as it provides a good balance of quality and CPU usage.
Horizontal resolution is automatically calculated, you only need to set the vertical resolution.

While resolution limiting is useful, it is also dangerous. Depending on how the game is coded,
resized videos may only take up part of the screen when played. You might get lucky and not have to fix anything.
This is completely up to the way the original game developer coded their game.
If you are compressing a RenPy game you can usually fix this, but the fix is different for every game.
Sometimes it is as simple as adding/changing a single line of code to the script.rpy file. Other times, it is much more involved.
Only use resolution limiting if you a confident that you can figure out how to make sure the videos play properly.
I provide a few hints in the resolution limit menu, if you are feeling adventurous.


Here you can access the various features of the YAC script. Options 1,2,3, and 6 are self-explanatory.
*Options are not case-sensitive*

This option uses a streamlined version of Sam's UnRen script to extract .rpa files.
The originals are not deleted so you will have to do that yourself later. They are usually only located in the main "game" folder.

This option deletes all audio from the video files.
Sometimes, game developers accidentally add audio tracks to their videos that don't actually contain any sound.
These "blank" audio tracks still take up space, so running this option can drop file sizes even more without effecting quality.
This option is generally safe to use, but obviously you should make sure the audio isn't actually needed!
You should run this option BEFORE compressing the video, but it will work either way.
If some videos have audio that you want to keep, just move them out of the "game" folder first.
Then, Move them back after the script is finished.

Go back to the quality select menu.

The YAC script is free(Libre AND Gratis) to re-distribute and modify.

Many thanks to these cool guys:
bas for the awesome RenCruncher
Sam for the essential UnRen.bat
PearlNecklaceProductions for the idea to keep track of files and skip those done before

for Adult Games, Comics, Mods, Cheats and more. All on free-to-use high-speed file hosts!

If images won't display correctly outside of game, download and install the webp codec for your OS here:

Here's the Windows version:

If videos won't play correctly outside of the game, download and install the webm directshow filters here:

======== DOWNLOAD ========

- -

V2.1 (Previous major release)
- -

  • Updated cwebp, ffmpeg, and nconvert to latest builds. Slight quality and speed improvements should be expected.
  • Reverted to using .cwebp for everything except .webp sources. Ran into some bugs with nconvert that I didn't like.
  • Simplified 64-bit check to reduce number of tools YAC relies on (Improved compatablity with Windows 11).

  • Updated cwebp, nconvert, & ffmpeg to latest stable versions
  • cwebp is now only used for lossless mode
  • GIF compression now uses animated webp instead of webm. This means web browsers will treat the files as pictures(like a GIF), which will improve compatibility with HTML games. Because of this, I'm now enabling GIF compression by default again.
  • Some minor bug fixes I don't even remember.

  • Added file size check (only replace files if smaller)
  • Added crash protection/crunch history (skip files already crunched)
  • Disabled .GIF compression by default, can be re-enabled with "GIF" option at main menu
  • Changed MUTE function and fixed issue where videos would be muted unintentionally
  • Improved .OGV compression support

  • Fixed issue where files wouldn't crunch if there were spaces in the folder names
  • Added the old "MUTE" option for those of you that missed it.
  • Made the main window smaller since it doesn't have to show as much info anymore

  • Re-wrote most of the processing/file-tracking code. You no longer have to keep track of the "Already_Crunched_List".
  • Split many of the script's functions into separate .bat files and stuffed them into the "YAC_Tools" folder. This should help me keep the main .bat file smaller and easier to understand.
  • Images, audio, and video will now process simultaneously; this should speed up the crunch overall as your CPU won't spend as much time waiting for each file to finish. I've seen an over 100% improvement(doubling) in overall speed with some games with many files. Simple games with few audio/video files will only see a small improvement.

  • Tweaked the presets a bit more to drop file size.
  • Added a timer to the script so now you know how long the crunch takes.
  • Adjusted presets to slightly increase video quality.
  • YAC is now a self-extracting archive; you no longer need an external program like 7-zip to use it.
  • Updated YAC tools to latest versions (as of 20/3/2021)
  • YAC will now try to avoid deleting original files if the crunched files get corrupted during encode.
  • Optimized video encoding settings and tools for a dramatic increase in encoding speed. Video encode speed is now at least 2x as fast as before. People with more than 4 cores will see the biggest gains.
  • Minimized unnecessary files in YAC tools, total download size is now 30% smaller!
  • Added .GIF compression support (converts to .webm)
  • Added a new "Ultra" quality preset. This preset maxes all quality settings and uses lossless image compression.
  • Removed "Mute" option as it isn't really necessary anymore(silent audio now uses insignificant space)
  • Fixed a bug that would sometimes cause the script to crash if a file path had parentheses in it.
  • Internal use only, never released

  • Updated YAC tools to latest versions(as of 18-12-2020)

  • Added the current directory to the titlebar of the window so you can more easily keep track of which game you are crunching; this is particularly useful when running multiple instances of YAC at the same time.
  • Process priority is now set to below normal; this should not significantly affect speed and will allow you to use your computer normally while encoding, even with multiple instances of YAC running at the same time.
  • Minor bug fixes

This update improves YACs ability to check if a file has been crunched before.

  • File tracking code changed to relative paths instead of absolute paths. This should help avoid issues when there are spaces or strange characters in the path to a file. This should also keep the size of the "Already_Crunched_list" lower, which might speed up searching it.

  • A new "S" option has been added to the menu. Selecting "S" will toggle checking if files have been crunched before. New entries will still be added to the "Already_Crunched_list". To improve speed, this option is automatically enabled if the list is empty.

    Checking the "Already_Crunched_list" slows down as it gets larger, especially after 10,000+ files have been crunched. If using YAC for multiple games make sure you delete the list every time you change games to avoid this slow down.

  • Code cleaned up and comments added

  • Bugfix custom quality setting (it now actually works :D)
  • Add file size comparison (YAC will now only replace files if new file is smaller than original)
  • setting image quality to 100 now enables lossless compression(for lossless inputs only)

Initial release
  • Like
Reactions: 1 user

Donation drives

Latest Updates page

everything that get donated will go to parceload who is developing the new latest updates page.
This donation drive ends in
Donation Drive
Click one of these buttons to initiate donation.
Top Bottom