Sequence Storm now working.
This commit is contained in:
		@@ -26,6 +26,37 @@ update() {
 | 
			
		||||
    fi
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
# Create the clipboard reading function for Sequence Storm
 | 
			
		||||
write_sequence_storm_reader() {
 | 
			
		||||
    if -e ~/.SequenceStormReader ]]; then
 | 
			
		||||
        return
 | 
			
		||||
    fi
 | 
			
		||||
# Here-document start
 | 
			
		||||
cat << "EOF" > ~/.SequenceStormReader
 | 
			
		||||
#! /bin/bash
 | 
			
		||||
 | 
			
		||||
export DISPLAY=:0
 | 
			
		||||
close=-1
 | 
			
		||||
unset cliptext
 | 
			
		||||
while [[ $close -ne 0 ]]; do
 | 
			
		||||
    tmp="$(xclip -selection clipboard -o)"
 | 
			
		||||
    if [ "$tmp" != "$cliptext" ] ; then
 | 
			
		||||
        cliptext="$tmp"
 | 
			
		||||
        spd-say -r 50 "$cliptext"
 | 
			
		||||
    fi
 | 
			
		||||
    sleep 0.05
 | 
			
		||||
    if [ $(pgrep -cu $USER SequenceStorm) -eq 0 -a $close -eq -1 ]; then
 | 
			
		||||
        continue
 | 
			
		||||
    fi
 | 
			
		||||
    close=$(pgrep -cu $USER SequenceStorm)
 | 
			
		||||
done
 | 
			
		||||
 | 
			
		||||
exit 0
 | 
			
		||||
EOF
 | 
			
		||||
# Here-document end
 | 
			
		||||
    chmod 755 ~/.SequenceStormReader
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
# Wine configuration section
 | 
			
		||||
 | 
			
		||||
checklist() {
 | 
			
		||||
@@ -79,6 +110,11 @@ checklist() {
 | 
			
		||||
    else
 | 
			
		||||
    errorList+=("Warning: Wine mono not found, some games may not work.")
 | 
			
		||||
    fi
 | 
			
		||||
    if command -v xclip &> /dev/null ; then
 | 
			
		||||
        echo "Xclip is installed."
 | 
			
		||||
    else
 | 
			
		||||
        errorList+=("Warning: Xclip is not installed. Some games may not speak.")
 | 
			
		||||
    fi
 | 
			
		||||
    if command -v xdotool &> /dev/null ; then
 | 
			
		||||
        echo "Xdotool is installed."
 | 
			
		||||
    else
 | 
			
		||||
@@ -233,6 +269,10 @@ game_launcher() {
 | 
			
		||||
            xdg-open "https://patreon.com/stormux"
 | 
			
		||||
            exit 0
 | 
			
		||||
        fi
 | 
			
		||||
        # for games that require custom scripts before launch
 | 
			
		||||
        if [[ "$game" =~ sequence-storm ]]; then
 | 
			
		||||
            [[ -x ~/.SequenceStormReader ]] && ~/.SequenceStormReader &
 | 
			
		||||
        fi
 | 
			
		||||
        local winePath="${game#*|}"
 | 
			
		||||
        winePath="${winePath%\\*.exe}"
 | 
			
		||||
        local wineExec="${game#*|}"
 | 
			
		||||
@@ -592,6 +632,7 @@ case "${game}" in
 | 
			
		||||
        export winVer="win10"
 | 
			
		||||
        install_wine_bottle
 | 
			
		||||
        unzip -d "$WINEPREFIX/drive_c/Program Files/sequence-storm" "${cache}/sequence-storm-win64.zip"
 | 
			
		||||
        write_sequence_storm_reader
 | 
			
		||||
        wget -O "$WINEPREFIX/drive_c/Program Files/sequence-storm/settings.json" "https://stormgames.wolfe.casa/downloads/sequencestorm-settings.json"
 | 
			
		||||
        add_launcher "c:\Program Files\sequence-storm\SequenceStorm.exe"
 | 
			
		||||
    ;;
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user