From 1b2ff4ff007be8b377430b57563de2ea554cee05 Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Tue, 2 Jan 2024 15:11:06 +0800 Subject: [PATCH] 1 --- webapp/controller/MatchController.class.php | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/webapp/controller/MatchController.class.php b/webapp/controller/MatchController.class.php index 12951990..64db3ccb 100644 --- a/webapp/controller/MatchController.class.php +++ b/webapp/controller/MatchController.class.php @@ -203,6 +203,13 @@ class MatchController extends BaseAuthedController { } error_log(json_encode($matchOkDb)); $matchInfo['state'] = 1; + $data = array( + 'zid' => '', + 'node_id' => '', + 'room_uuid' => '', + 'start_time' => myself()->_GetNowTime(), + 'team_list' => array() + ); $teamList = array(); { $teamDb = $this->readTeamDb($r, $teamUuid); @@ -217,6 +224,9 @@ class MatchController extends BaseAuthedController { )); } array_push($teamList, $teamInfo); + $data['zid'] = $teamDb['zid']; + $data['node_id'] = $teamDb['node_id']; + $data['room_uuid'] = $teamDb['team_uuid']; } { $teamDb = $this->readTeamDb($r, $matchOkDb['target_team']); @@ -230,8 +240,9 @@ class MatchController extends BaseAuthedController { array_push($teamList, $teamInfo); } } - $payload = md5(json_encode($teamList) . '520d8eAbB(8cf1^#$^&!@d833a42c820432PDAFE^^)') . - ":moba_room|" . json_encode($teamList); + $data['team_list'] = $teamList; + $payload = md5(json_encode($data) . '520d8eAbB(8cf1^#$^&!@d833a42c820432PDAFE^^)') . + ":moba_room|" . json_encode($data); $matchInfo['join_msg'] = array( 'team_uuid' => $teamUuid, 'payload' => $payload