Arg
This commit is contained in:
parent
f5e85affa2
commit
d642fbb5c9
1 changed files with 9 additions and 17 deletions
|
@ -21,34 +21,26 @@ fi
|
|||
|
||||
mkdir -p ${SAVE_DIR}
|
||||
|
||||
params=(
|
||||
"-config" "${CONFIG}"
|
||||
"-savedir" "${SAVE_DIR}"
|
||||
"-width" "1152"
|
||||
"-height" "1920"
|
||||
"+vid_fps" "1"
|
||||
"+cl_capfps" "0"
|
||||
"+vid_renderer" "0"
|
||||
"+vid_glswfb" "0"
|
||||
)
|
||||
params=" -config ${CONFIG} -savedir ${SAVE_DIR}"
|
||||
params+=" -width 1152 -height 1920 +vid_fps 1 +cl_capfps 0 +vid_renderer 0 +vid_glswfb 0"
|
||||
|
||||
# EXT can be wad, WAD, iwad, IWAD, pwad, PWAD or doom
|
||||
EXT=${1#*.}
|
||||
|
||||
# If its not a simple wad (extension .doom) read the file and parse the data
|
||||
if [ "${EXT}" == "doom" ]; then
|
||||
if [ ${EXT} == "doom" ]; then
|
||||
dos2unix "${1}"
|
||||
while IFS== read -r key value; do
|
||||
if [ "${key}" == "IWAD" ]; then
|
||||
params+=("-iwad" "${value}")
|
||||
if [ "$key" == "IWAD" ]; then
|
||||
params+=" -iwad $value"
|
||||
fi
|
||||
if [ "${key}" == "MOD" ]; then
|
||||
params+=("-file" "${value}")
|
||||
if [ "$key" == "MOD" ]; then
|
||||
params+=" -file $value"
|
||||
fi
|
||||
done <"${1}"
|
||||
else
|
||||
params+=("-iwad" "${1}")
|
||||
params+=" -iwad ${1}"
|
||||
fi
|
||||
|
||||
cd "${RUN_DIR}"
|
||||
/usr/bin/lzdoom "${params[@]}" >/var/log/lzdoom.log 2>&1
|
||||
echo ${params} | xargs /usr/bin/lzdoom >/var/log/lzdoom.log 2>&1
|
||||
|
|
Loading…
Reference in a new issue