Skip to content

Latest commit

 

History

15 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Special K Replacement Script

This PowerShell script is specifically designed to update "Special K" DLL files in game directories. It ensures that only the "Special K" DLLs are updated, supports bulk operations across multiple game directories, and prevents unintentional updates through a configurable blacklist.

Features

  • DLL Replacement: Automatically replaces existing Special K DLLs with updated versions for both 32-bit and 64-bit architectures.
  • Multi-Directory Support: Process multiple game directories at once by specifying them in a game_paths.txt file or dragging a directory onto the script.
  • Blacklist Management: Skip specific game folders by adding their names to a blacklist.txt file.
  • Comments in Configuration Files: Lines starting with ; in game_paths.txt or blacklist.txt are treated as comments and ignored.
  • Dynamic Backup Support: If replacement DLLs are not found locally, the script looks for backups in %LocalAppData%\Programs\Special K (default install location for Special K).
  • Verbose Mode: Use -v or -verbose flag for detailed logging of what the script is doing.
  • Optimized Scanning: Only scans directories containing executables and checks known Special K target DLL names for fast performance.
  • Mod Loader Aware: Automatically skips mod loader directories (MelonLoader, BepInEx, doorstop_libs).
  • Colored Output: Provides clear and color-coded log messages for better readability.

Requirements

  • Windows OS
  • PowerShell
  • SpecialK

Installation

  1. Clone this repository or download the script.
  2. Ensure you have the updated SpecialK32.dll and SpecialK64.dll files either:
    • In the same folder as the script.
    • In the backup folder: %LocalAppData%\Programs\Special K (default install location for Special K).

The script will prioritise DLLs found alongside the script before using the local SpecialK install.

Usage

1. Add Game Paths

  • Create a game_paths.txt file in the script directory.
  • Add paths to the game directories you want to process, one per line.
  • Add comments using lines starting with ;.

Example:

; Path to my Steam games
C:\Games\Steam

; Another path
D:\Games\Other

2. Add Blacklisted Games

  • Create a blacklist.txt file in the script directory.
  • Add game folder names to exclude from processing, one per line.
  • Add comments using lines starting with ;.

Example:

; Skip CoreKeeper
CoreKeeper

; Skip DarkAndDarker
DarkAndDarker

3. Run the Script

# Standard usage (reads from game_paths.txt)
update_sk.bat

# Process a specific directory
update_sk.bat "C:\Games\SomeGame"

# Verbose mode (detailed logging)
update_sk.bat -v
update_sk.bat -verbose

# Verbose mode with specific directory
update_sk.bat -v "C:\Games\SomeGame"

You can also drag and drop a game directory onto update_sk.bat to process only that folder.

Output

The script provides color-coded output:

  • Cyan: General progress (e.g., searching directories).
  • Green: Successful replacements and matches.
  • Yellow: Warnings or fallback paths used.
  • Magenta: Skipped folders (blacklisted).
  • Red: Errors or critical issues.
  • Dark Gray: Verbose logging (when -v flag is used).

At the end of execution, the script displays a summary:

  • Total games searched.
  • Total games updated.
  • Total games skipped (blacklisted).

Pause on Completion

The script waits for a keypress before closing, so you can review the log output.

License

This script is provided "as is" without warranty of any kind. Use it at your own risk.


For questions or support, feel free to create an issue in this repository.

Note

Dragging and dropping directly onto the .ps1 script is not supported; always use the update_sk.bat file for execution.

About

This PowerShell script is specifically designed to update "Special K" DLL files in game directories. It ensures that only the "Special K" DLLs are updated, supports bulk operations across multiple game directories, and prevents unintentional updates through a configurable blacklist.

Topics

Resources

Stars

3 stars

Watchers

1 watching

Forks

Sponsor this project

Contributors

Languages