From de39454cb44a2e2b8d67ed351c494b3b306d52b9 Mon Sep 17 00:00:00 2001 From: Storm Dragon Date: Sun, 2 Oct 2022 13:06:15 -0400 Subject: [PATCH] Hopefully improved the installer for Bokurano Daibouken 3. It should now prompt for the translation file and provide the url where it can be obtained. --- audiogame-manager.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/audiogame-manager.sh b/audiogame-manager.sh index 7f998e0..2edeb9c 100755 --- a/audiogame-manager.sh +++ b/audiogame-manager.sh @@ -1601,13 +1601,17 @@ case "${game}" in add_launcher "c:\Program Files\bloodshed.exe" ;; "Bokurano Daibouken 3") + if [[ ! -r "${cache}/bk3-dict.dat" ]]; then + echo "http://www.nyanchangames.com/order/bk3translate.html" | xclip -selection clipboard 2> /dev/null + dialog --backtitle "Audiogame manager" --msgbox "If you would like English translations, the file is available at http://www.nyanchangames.com/order/bk3translate.html. Save the dict.dat file to your Downloads or Desktop directory. For convenience the url has been copied to your clipboard. Press enter when you are ready to continue." -1 -1 --stdout + fi dictFile="" for i in "${HOME}/Downloads/dict.dat" "${HOME}/Desktop/dict.dat" ; do if [[ -r "$i" ]]; then dictFile="$i" fi done - if [[ "$i" != "" ]] && [[ ! -r "${cache}/bk3-dict.dat" ]]; then + if [[ "${#i}" -ge 3 ]] && [[ ! -r "${cache}/bk3-dict.dat" ]]; then dialog --backtitle "Audiogame manager" --yesno "Possible English translation file found at $dictFile. Would you like to use it for BK3?" -1 -1 --stdout && cp -v "$dictFile" "${cache}/bk3-dict.dat" fi export bottle="nyanchan"