Fix some critters.

After about half an hour of cussin and spitting tobacco juice, I came
to some discoveries:
* The clipboard translator wasn't even launching successfully.
* For BKs 1 and 2, remove the nvda dll thereby forcing it to use the
clipboard reader.
* Fix up BK2 to go into the right bottle; it is a 32-bit game.
This commit is contained in:
2025-10-07 10:14:54 -04:00
parent ba0075e74b
commit e3289b92cb
3 changed files with 35 additions and 15 deletions

View File

@@ -1,5 +1,8 @@
#!/usr/bin/env bash
# Get script directory for relative paths
scriptDir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
# Dialog accessibility
export DIALOGOPTS='--no-lines --visit-items'
@@ -171,7 +174,7 @@ game_installer() {
# Create the menu of available games by reading from .install directory
declare -a menuList
# Get all .sh files from .install directory, excluding those starting with # as first line.
mapfile -t sortedGames < <(for f in "${0%/*}/.install/"*.sh; do
mapfile -t sortedGames < <(for f in "${scriptDir}/.install/"*.sh; do
# Skip if first line starts with #
[[ $(head -n1 "$f") == "#"* ]] && continue
echo "${f##*/%.sh}"
@@ -214,7 +217,7 @@ game_installer() {
;;
*)
# Convert game name to filename format
local installScript="${0%/*}/.install/${game}.sh"
local installScript="${scriptDir}/.install/${game}.sh"
# Check if install script exists
if [[ -f "$installScript" ]]; then
# Source and execute the install script
@@ -341,7 +344,7 @@ kill_game() {
# for games that require custom scripts before launch or custom launch parameters
custom_launch_parameters() {
if [[ "${game[2]}" == "Dragon Pong" ]]; then
"${0%/*}/speech/speak_window_title.sh" DragonPong.exe &
"${scriptDir}/speech/speak_window_title.sh" DragonPong.exe &
pushd "$(winepath "$winePath")"
wine "$wineExec"
popd
@@ -349,13 +352,15 @@ custom_launch_parameters() {
fi
# executioner's-rage: DLL replacement now handled by update_nvda_dlls()
if [[ "${game[2]}" == "Laser Breakout" ]]; then
"${0%/*}/speech/speak_window_title.sh" play.exe &
"${scriptDir}/speech/speak_window_title.sh" play.exe &
fi
if [[ "${game[2]}" == "Bokurano Daibouken 2" ]]; then
"${0%/*}/speech/clipboard_translator.sh" "${game[1]}" bokurano-daibouken2 &
find "${WINEPREFIX}/drive_c/nyanchangame/bk2" -type f -name 'nvdaControllerClient.dll' -exec rm -v "{}" \;
"${scriptDir}/speech/clipboard_translator.sh" "play.exe" bokurano-daibouken2 &
fi
if [[ "${game[2]}" == "Bokurano Daibouken" ]]; then
"${0%/*}/speech/clipboard_translator.sh" "${game[1]}" bokurano-daibouken &
find "${WINEPREFIX}/drive_c/nyanchangame/bk" -type f -name 'nvdaControllerClient.dll' -exec rm -v "{}" \;
"${scriptDir}/speech/clipboard_translator.sh" "play.exe" bokurano-daibouken &
fi
if [[ "${game[2]}" == "Bokurano Daibouken 3" ]]; then
dictPath="$(winepath "${winePath}")"
@@ -365,21 +370,21 @@ custom_launch_parameters() {
# DLL replacement now handled by update_nvda_dlls()
if [[ ! -d "${dictPath}/dict" ]] && [[ ! -r "${cache}/bk3-dict.dat" ]]; then
find "${WINEPREFIX}/drive_c/nyanchangame/bk3" -type f -name 'nvdaControllerClient.dll' -exec rm -v "{}" \;
"${0%/*}/speech/clipboard_translator.sh" "${game[1]}" bokurano-daibouken3 &
"${scriptDir}/speech/clipboard_translator.sh" "play.exe" bokurano-daibouken3 &
fi
fi
if [[ "${game[2]}" == "Bop It Emulator" ]]; then
"${0%/*}/speech/speak_window_title.sh" bop.exe &
"${scriptDir}/speech/speak_window_title.sh" bop.exe &
fi
if [[ "${game[2]}" == "Road to Rage" ]]; then
"${0%/*}/speech/speak_window_title.sh" trtr.exe &
"${scriptDir}/speech/speak_window_title.sh" trtr.exe &
fi
if [[ "${game[2]}" == "Sequence Storm" ]]; then
"${0%/*}/speech/clipboard_reader.sh" SequenceStorm &
"${scriptDir}/speech/clipboard_reader.sh" SequenceStorm &
fi
#if [[ "${game[2]}" == "Shadow Line" ]]; then
#find "${WINEPREFIX}/drive_c/" -type f -name 'nvdaControllerClient.dll' -exec rm -v "{}" \;
#"${0%/*}/speech/clipboard_translator.sh" play_sr.exe shadow-line &
#"${scriptDir}/speech/clipboard_translator.sh" play_sr.exe shadow-line &
#fi
# sketchbook: DLL replacement now handled by update_nvda_dlls()
if [[ "${game[2]}" == "Audiodisc" ]]; then