Add dialogs for death match setup.

This commit is contained in:
Storm Dragon 2024-01-21 13:48:58 -05:00
parent 98ce0a96ee
commit b6d761f67e

View File

@ -30,7 +30,6 @@ grepStrings=(
'-e' '^"cl_run"'
'-e' '^Game saved. '
'-e' '^A secret is revealed!$'
'-e' '^MAP[0-9]*'
'-e' '^Player[: ]'
'-e' '^Please select a game wad \(or 0 to exit\):'
'-e' '^You have no keys in your pocket!$'
@ -39,7 +38,6 @@ grepStrings=(
sedStrings=(
'-e' 's/"cl_run" = "true"/run/'
'-e' 's/"cl_run" = "false"/walk/'
'-e' 's/MAP0\([1-9]\)/Map \1/'
'-e' 's:.*/:Game saved. (:'
)
@ -100,10 +98,18 @@ case ${buttonCode} in
[6]="2 4"
[7]="2 4"
[8]="2 4")
# Dialog statement to choose map goes here
map="1"
# Dialog statement to choose fraglimit goes here
fraglimit=20
map="$(dialog --backtitle "Select Map" \
--clear \
--no-tags \
--cancel-label "Exit" \
--ok-label "Host" \
--menu "Please select one" 0 0 0 "${maps[@]}" --stdout)"
fraglimit="$(dialog --backtitle "Fraglimit" \
--clear \
--ok-label "Next" \
--cancel-label "Exit" \
--rangebox "Select Fraglimit" -1 -1 1 1000000 20 --stdout)"
[[ $? -eq 1 ]] && exit 0
# Get ip address
yourIpAddress="$(curl -4s https://icanhazip.com)"
players="$(dialog --backtitle "Host Deathmatch Game" \