Last active
August 19, 2024 14:04
-
-
Save DevSrSouza/cbe9b12522c091be29acb46a77d710aa to your computer and use it in GitHub Desktop.
Stardew Valley Linux script for faster tool (Animation cancelation)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pressTool() | |
{ | |
xdotool keydown 'c' | |
sleep 0.090 | |
xdotool keyup 'c' | |
sleep 0.042 | |
xdotool keydown 'Shift_R+Delete+R' | |
sleep 0.005 | |
xdotool keyup 'Shift_R+Delete+R' | |
} | |
i=0 | |
for pid in $(pgrep -f `basename $0`); do | |
if [ $pid != $$ ]; then | |
((i=i+1)) | |
fi | |
done | |
# for some reason xbindkeys create two pids but only one works | |
if ((i <= 1)); then | |
pressTool | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment