From 6fb1750b923b97a377d6ef8ad4a25b501e65b39d Mon Sep 17 00:00:00 2001 From: David Vazgenovich Shakaryan Date: Fri, 20 May 2022 15:03:44 -0700 Subject: web: support visit log for 3+ player matches The new match modes are for testing. They'll eventually be removed in favour of true configurability. --- web/web_control.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'web/web_control.c') diff --git a/web/web_control.c b/web/web_control.c index b0a777c..ca45ed4 100644 --- a/web/web_control.c +++ b/web/web_control.c @@ -263,6 +263,10 @@ void match_mode_selected(int mode) } else if (mode == M_PVPVP) { match_opts->p1_name = "Player 1"; match_opts->p2_name = "Player 2"; + } else if (mode == M_PVCVCVC) { + match_opts->p1_name = "User"; + match_opts->p2_type = PT_COMP; + match_opts->p2_name = "Computer 1"; } prompt_match_opts(); @@ -278,6 +282,10 @@ void start_match() match_opts->p2_name ? match_opts->p2_name : "oi"); if (match_opts->mode == M_PVPVP) match_add_player(match_opts->start_pts, PT_USER, "Player 3"); + else if (match_opts->mode == M_PVCVCVC) { + match_add_player(match_opts->start_pts, PT_COMP, "Computer 2"); + match_add_player(match_opts->start_pts, PT_COMP, "Computer 3"); + } scoreboard_show_info(match_num_players()); for (int i = 1; i <= match_num_players(); ++i) { -- cgit v1.2.3-70-g09d2