Skip to content

Instantly share code, notes, and snippets.

@personinblack
Last active March 15, 2021 11:32
Show Gist options
  • Save personinblack/30e6d8d642811127a0252419e9e61e07 to your computer and use it in GitHub Desktop.
Save personinblack/30e6d8d642811127a0252419e9e61e07 to your computer and use it in GitHub Desktop.
A script for Valorant to fallback to default text language while still using the selected voice language
#!/bin/bash
#
# val.sh - personinblack
# I run this inside Git Bash (MinGW) and haven't tried any other. Cygwin installation takes long because it
# has to download a lot of stuff. WSL requires Windows Store app and I don't have that. Git Bash is the easiest by far.
BACKUP_DIR="/c/Users/User/backup"
VALORANT_DIR="C:\Riot Games\VALORANT"
CLIENT_DIR="C:\Riot Games\Riot Client"
NO_TASK="INFO: No tasks are running which match the specified criteria."
"$CLIENT_DIR\RiotClientServices.exe" --launch-product=valorant --launch-patchline=live &
disown
cd "$VALORANT_DIR\live\ShooterGame\Content\Paks\\"
mkdir $BACKUP_DIR && echo 1. Created backup dir.
while :
do
if [ "$(tasklist -fi "IMAGENAME eq VALORANT-Win64-Shipping.exe")" != "$NO_TASK" ]; then
mv *_Text-* $BACKUP_DIR && echo 2. Moved text files.
break
fi
done
echo Waiting for the Valorant window to show up.
while :
do
if [ "$(tasklist -fi "windowtitle eq Valorant*")" != "$NO_TASK" ]; then
sleep 3
mv $BACKUP_DIR/* ./ && echo 3. Reverted from backup.
rmdir $BACKUP_DIR && echo 4. Removed backup dir.
break
fi
done
echo 5. End.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment