0 of 0

File information

Last updated

Original upload

Created by

Gametism

Uploaded by

Gametism

Virus scan

Safe to use

About this mod

This batch script is a shader cache cleaner designed for NVIDIA, AMD, and Intel graphics drivers, along with an option to add custom shader cache directories.

Permissions and credits
Donations
Key Features:


Check for Administrative Privileges:

The script checks if it has administrative privileges. If not, it restarts itself with elevated rights using PowerShell.

Shader Cache Locations:

Predefined cache locations for NVIDIA, AMD, and Intel drivers are stored in environment variables (NVidia_cache1, AMD_cache1, etc.).

Log Creation:

A log file (ShaderCacheCleaner.log) is created in the user's %LOCALAPPDATA% directory, where the script logs its actions.

Confirmation Before Deletion:

The script displays the shader cache directories it plans to delete and asks the user for confirmation using the choice command. If the user declines, it logs that the deletion was skipped.

Cache Deletion:

Upon user approval, the script proceeds to delete each cache folder using the :delete_cache subroutine, which checks if the directory exists, deletes it, and logs the result.

Custom Shader Cache Deletion:

After handling the predefined caches, the script gives the user the option to input a custom path for any additional shader caches to delete (e.g., for specific games). It then attempts to delete the custom path using the :delete_file_or_directory subroutine.

Instructions:

If any files are still in use, the script suggests restarting the computer or resetting the shader cache from the GPU control panel.



If you'd like to support my work you can say "Thanks" in Posts or