updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / darkforces / darkforces.sh
blob08e3245b3dce1addcd87c26a65e426dad355718d
1 #! /bin/bash
3 if [ ! -f "/usr/lib/libdarkforces.sh" ]; then
4 echo "Can't load /usr/lib/libdarkforces.sh" >&2
5 exit 1
6 else
7 . "/usr/lib/libdarkforces.sh"
8 fi
10 readonly SCRIPT_NAME="${0}"
12 darkforces.script.game() {
13 local batchScript='
14 mount -u c
15 mount c "'"${APP_DIR}"'"
18 if darkforces.firstRun; then
19 batchScript+='
20 cd \
21 rename cd.id cd.bak
22 cd \dark
23 install.exe
24 cd \
25 rename cd.bak cd.id
28 batchScript+="
29 cd \\dark
30 dark.exe $@
31 exit
34 SDL_VIDEO_X11_WMCLASS=$(basename "${SCRIPT_NAME%.*}") dosbox -conf "${DOSBOX_CONF}" -exit -c "${batchScript}"
37 darkforces.run darkforces.script.game "$@"