From f47f7334102564dc64f8f6aa2f96eccfb2857cbd Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Mon, 25 Dec 2023 19:26:21 +0800 Subject: [PATCH] 1 --- doc/Match.py | 23 +++++++++++++++++++++++ doc/_common.py | 42 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 65 insertions(+) create mode 100644 doc/Match.py diff --git a/doc/Match.py b/doc/Match.py new file mode 100644 index 00000000..6e32a387 --- /dev/null +++ b/doc/Match.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- + +import _common + +class Match(object): + + def __init__(self): + self.apis = [ + { + 'name': 'getMatchInfo', + 'desc': '获取匹配信息', + 'group': 'Match', + 'url': 'webapp/index.php?c=Match&a=getMatchInfo', + 'params': [ + _common.ReqHead(), + ['team_uuid', '', '队伍唯一id'], + ], + 'response': [ + _common.RspHead(), + ['info', _common.MatchInfo(), '队伍唯一id'], + ] + } + ] diff --git a/doc/_common.py b/doc/_common.py index 66cbe777..74affbb7 100644 --- a/doc/_common.py +++ b/doc/_common.py @@ -1527,3 +1527,45 @@ class BattleTeam(object): ['team_uuid','','队伍唯一id'], ['!members', BattleData(), '成员数据'], ] + +class MatchMember(object): + + def __init__(self): + self.fields = [ + ['account_id', '', '账号id'], + ['address', '', 'openid'], + ['name', '', '用户名字'], + ['hero_uniId', 0, 'hero uniid'], + ['hero_id', 0, 'hero itemId'], + ['hero_skin', 0, '英雄皮肤 itemId'], + ['head_id', 0, '头像id'], + ['level', 0, '等级'], + ['exp', 0, '经验'], + ['rank', 0, '段位'], + ['pve_instance_id', 0, 'pve难度id'], + ['parachute', 0, '降落伞id'], + ['presetInfo', HeroPreset(), '备战信息'], + ['game_times', 0, '游戏次数'], + ['win_times', 0, '胜利次数'], + ['kills', 0, '击杀数'], + ['is_leader', 0, '是否队长'], + ['is_ready', 0, '是否准备'], + ['permission', 0, '邀请许可'], + ['createtime', 0, '账号创建时间'], + ] + +class MatchTeam(object): + + def __init__(self): + self.fields = [ + ['team_uuid','','队伍唯一id'], + ['!members', BattleData(), '成员数据'], + ] + +class MatchInfo(object): + + def __init__(self): + self.fields = [ + ['state',0,'状态 0:匹配中 1:匹配成功'], + ['!team_list', MatchTeam(), '队伍列表(客户端自行判断所属哪个队伍)'], + ]