make_mapdef.sh: read mins/maxs/model only when editor_mins/maxs/model weren't explicitly set

This commit is contained in:
Marco Cawthorne 2023-09-20 16:12:14 -07:00
parent c314e880fd
commit e93dc09805
Signed by: eukara
GPG Key ID: CE2032F0A2882A22
1 changed files with 25 additions and 1 deletions

View File

@ -43,16 +43,40 @@ do
printf -- "$VAL" > "/tmp/def_maxs"
fi
if [ "$KEY" == "mins" ]
then
if [ -z $(cat "/tmp/def_mins") ]
then
printf -- "$VAL" > "/tmp/def_mins"
fi
fi
if [ "$KEY" == "maxs" ]
then
if [ -z $(cat "/tmp/def_maxs") ]
then
printf -- "$VAL" > "/tmp/def_maxs"
fi
fi
if [ "$KEY" == "editor_usage" ]
then
printf -- "$VAL" > "/tmp/def_usage"
fi
if [ "$KEY" == "model" ]
if [ "$KEY" == "editor_model" ]
then
printf -- "$VAL" > "/tmp/def_model"
fi
if [ "$KEY" == "model" ]
then
if [ -z $(cat "/tmp/def_model") ]
then
printf -- "$VAL" > "/tmp/def_model"
fi
fi
if [ "$SEG1" == "}" ]
then
KEY_NAME=$(cat "/tmp/def_name")