#!/bin/bash
. findwine
if [ -e "$HOME/.wine/c/Programme/SplashKiller/SplashKillerRunner.exe" ]; then
  $WINE "c:\Programme\SplashKiller\SplashKillerRunner.exe" &
  spkr=$!
  sleep 1s
fi
$WINE "c:\\Program Files\\The Bat!\\thebat.exe" ${PARAM:+"$PARAM"} &>/dev/null &
while true; do
  ps axwww|grep thebat.exe|grep -v "grep thebat.exe" &>/dev/null
  [ "$?" != 0 ] && break
  sleep 1s
done
[ "$spkr" = "" ] || kill "$spkr"
