├── .editorconfig ├── .gitignore ├── README.md ├── __init__.py ├── example.py ├── example_admin.py ├── ms ├── .tool-versions ├── __init__.py ├── base.py ├── generate_proto_file.py ├── liqi.json ├── ms-plugin.py ├── protocol.proto ├── protocol_pb2.py └── rpc.py ├── ms_tournament ├── __init__.py ├── base.py ├── generate_proto_file.py ├── liqi_admin.json ├── ms-admin-plugin.py ├── protocol_admin.proto ├── protocol_admin_pb2.py └── rpc.py ├── requirements.txt └── setup.py /.editorconfig: -------------------------------------------------------------------------------- 1 | # http://editorconfig.org 2 | root = true 3 | 4 | [*.py] 5 | charset = utf-8 6 | indent_style = space 7 | indent_size = 4 8 | end_of_line = lf 9 | insert_final_newline = true -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .idea 2 | env 3 | 4 | *.py[cod] 5 | __pycache__ 6 | .DS_Store 7 | 8 | MANIFEST 9 | dist/* 10 | *.egg-info 11 | build/* 12 | 13 | 14 | temp 15 | temp.py -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | The idea of repository based on https://github.com/chaserhkj/PyMajSoul/ 2 | 3 | Python wrappers for Majsoul allow you to interact with their servers from Python scripts. 4 | 5 | ## For User 6 | 7 | 1. Install python packages from `requirements.txt` 8 | 2. `python example.py -u username -p password` 9 | 10 | This example is working only with **Python3.7+**. 11 | 12 | Also, you need to have an account from CN server to run this example, because only accounts from CN server has the ability to login with login and password. 13 | 14 | If you want to login to EN or JP servers you need to write your code to authenticate via email code or social network. Protobuf wrapper from this repository contains all needed API objects for that. 15 | 16 | ## For Developer 17 | 18 | ### Requirements 19 | 20 | 1. Install python packages from `requerements.txt` 21 | 1. Install protobuf compiler `sudo apt install protobuf-compiler` 22 | 23 | ### How to update protocol files to the new version 24 | 25 | It was tested on Ubuntu. 26 | 27 | 1. Download the new `liqi.json` file from MS (find it in the network tab of your browser) and put it to `ms/liqi.json` 28 | 1. `python generate_proto_file.py` 29 | 1. `protoc --python_out=. protocol.proto` 30 | 1. `chmod +x ms-plugin.py` 31 | 1. `sudo cp ms-plugin.py /usr/bin/ms-plugin.py` 32 | 1. `protoc --custom_out=. --plugin=protoc-gen-custom=ms-plugin.py ./protocol.proto` 33 | 34 | 35 | ### How to update protocol files for manager API to the new version 36 | 37 | 1. Prepare new `liqi_admin.json` file from MS tournament manager panel 38 | 1. `python ms_tournament/generate_proto_file.py` 39 | 1. `protoc --python_out=. protocol_admin.proto` 40 | 1. `chmod +x ms-admin-plugin.py` 41 | 1. `sudo cp ms-admin-plugin.py /usr/bin/ms-admin-plugin.py` 42 | 1. `protoc --custom_out=. --plugin=protoc-gen-custom=ms-admin-plugin.py ./protocol_admin.proto` 43 | 44 | ### How to release new version 45 | 46 | 1. `pip install twine` 47 | 2. `python setup.py sdist` 48 | 3. `twine upload dist/*` 49 | -------------------------------------------------------------------------------- /__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MahjongRepository/mahjong_soul_api/314c6c935d60bb788084fc60c30df42661543434/__init__.py -------------------------------------------------------------------------------- /example.py: -------------------------------------------------------------------------------- 1 | import asyncio 2 | import hashlib 3 | import hmac 4 | import logging 5 | import random 6 | import uuid 7 | from optparse import OptionParser 8 | 9 | import aiohttp 10 | 11 | from ms.base import MSRPCChannel 12 | from ms.rpc import Lobby 13 | import ms.protocol_pb2 as pb 14 | from google.protobuf.json_format import MessageToJson 15 | 16 | 17 | logging.basicConfig( 18 | level=logging.INFO, format="%(asctime)s %(levelname)s: %(message)s", datefmt="%Y-%m-%d %H:%M:%S" 19 | ) 20 | 21 | MS_HOST = "https://game.maj-soul.com" 22 | 23 | 24 | async def main(): 25 | """ 26 | Login to the CN server with username and password and get latest 30 game logs. 27 | """ 28 | parser = OptionParser() 29 | parser.add_option("-u", "--username", type="string", help="Your account name.") 30 | parser.add_option("-p", "--password", type="string", help="Your account password.") 31 | parser.add_option("-l", "--log", type="string", help="Your log UUID for load.") 32 | 33 | opts, _ = parser.parse_args() 34 | username = opts.username 35 | password = opts.password 36 | log_uuid = opts.log 37 | 38 | if not username or not password: 39 | parser.error("Username or password cant be empty") 40 | 41 | lobby, channel, version_to_force = await connect() 42 | await login(lobby, username, password, version_to_force) 43 | 44 | if not log_uuid: 45 | game_logs = await load_game_logs(lobby) 46 | logging.info("Found {} records".format(len(game_logs))) 47 | else: 48 | game_log = await load_and_process_game_log(lobby, log_uuid, version_to_force) 49 | logging.info("game {} result : \n{}".format(game_log.head.uuid, game_log.head.result)) 50 | 51 | await channel.close() 52 | 53 | 54 | async def connect(): 55 | async with aiohttp.ClientSession() as session: 56 | async with session.get("{}/1/version.json".format(MS_HOST)) as res: 57 | version = await res.json() 58 | logging.info(f"Version: {version}") 59 | version = version["version"] 60 | version_to_force = version.replace(".w", "") 61 | 62 | async with session.get("{}/1/v{}/config.json".format(MS_HOST, version)) as res: 63 | config = await res.json() 64 | logging.info(f"Config: {config}") 65 | 66 | url = config["ip"][0]["region_urls"][1]["url"] 67 | 68 | async with session.get(url + "?service=ws-gateway&protocol=ws&ssl=true") as res: 69 | servers = await res.json() 70 | logging.info(f"Available servers: {servers}") 71 | 72 | servers = servers["servers"] 73 | server = random.choice(servers) 74 | endpoint = "wss://{}/gateway".format(server) 75 | 76 | logging.info(f"Chosen endpoint: {endpoint}") 77 | channel = MSRPCChannel(endpoint) 78 | 79 | lobby = Lobby(channel) 80 | 81 | await channel.connect(MS_HOST) 82 | logging.info("Connection was established") 83 | 84 | return lobby, channel, version_to_force 85 | 86 | 87 | async def login(lobby, username, password, version_to_force): 88 | logging.info("Login with username and password") 89 | 90 | uuid_key = str(uuid.uuid1()) 91 | 92 | req = pb.ReqLogin() 93 | req.account = username 94 | req.password = hmac.new(b"lailai", password.encode(), hashlib.sha256).hexdigest() 95 | req.device.is_browser = True 96 | req.random_key = uuid_key 97 | req.gen_access_token = True 98 | req.client_version_string = f"web-{version_to_force}" 99 | req.currency_platforms.append(2) 100 | 101 | res = await lobby.login(req) 102 | token = res.access_token 103 | if not token: 104 | logging.error("Login Error:") 105 | logging.error(res) 106 | return False 107 | 108 | return True 109 | 110 | 111 | async def load_game_logs(lobby): 112 | logging.info("Loading game logs") 113 | 114 | records = [] 115 | current = 1 116 | step = 30 117 | req = pb.ReqGameRecordList() 118 | req.start = current 119 | req.count = step 120 | res = await lobby.fetch_game_record_list(req) 121 | records.extend([r.uuid for r in res.record_list]) 122 | 123 | return records 124 | 125 | 126 | async def load_and_process_game_log(lobby, uuid, version_to_force): 127 | logging.info("Loading game log") 128 | 129 | req = pb.ReqGameRecord() 130 | req.game_uuid = uuid 131 | req.client_version_string = f"web-{version_to_force}" 132 | res = await lobby.fetch_game_record(req) 133 | 134 | record_wrapper = pb.Wrapper() 135 | record_wrapper.ParseFromString(res.data) 136 | 137 | game_details = pb.GameDetailRecords() 138 | game_details.ParseFromString(record_wrapper.data) 139 | 140 | game_records_count = len(game_details.records) 141 | logging.info("Found {} game records".format(game_records_count)) 142 | 143 | round_record_wrapper = pb.Wrapper() 144 | is_show_new_round_record = False 145 | is_show_discard_tile = False 146 | is_show_deal_tile = False 147 | 148 | for i in range(0, game_records_count): 149 | round_record_wrapper.ParseFromString(game_details.records[i]) 150 | 151 | if round_record_wrapper.name == ".lq.RecordNewRound" and not is_show_new_round_record: 152 | logging.info("Found record type = {}".format(round_record_wrapper.name)) 153 | round_data = pb.RecordNewRound() 154 | round_data.ParseFromString(round_record_wrapper.data) 155 | print_data_as_json(round_data, "RecordNewRound") 156 | is_show_new_round_record = True 157 | 158 | if round_record_wrapper.name == ".lq.RecordDiscardTile" and not is_show_discard_tile: 159 | logging.info("Found record type = {}".format(round_record_wrapper.name)) 160 | discard_tile = pb.RecordDiscardTile() 161 | discard_tile.ParseFromString(round_record_wrapper.data) 162 | print_data_as_json(discard_tile, "RecordDiscardTile") 163 | is_show_discard_tile = True 164 | 165 | if round_record_wrapper.name == ".lq.RecordDealTile" and not is_show_deal_tile: 166 | logging.info("Found record type = {}".format(round_record_wrapper.name)) 167 | deal_tile = pb.RecordDealTile() 168 | deal_tile.ParseFromString(round_record_wrapper.data) 169 | print_data_as_json(deal_tile, "RecordDealTile") 170 | is_show_deal_tile = True 171 | 172 | return res 173 | 174 | 175 | def print_data_as_json(data, type): 176 | json = MessageToJson(data) 177 | logging.info("{} json {}".format(type, json)) 178 | 179 | 180 | if __name__ == "__main__": 181 | asyncio.run(main()) 182 | -------------------------------------------------------------------------------- /example_admin.py: -------------------------------------------------------------------------------- 1 | import asyncio 2 | import hashlib 3 | import hmac 4 | import logging 5 | import random 6 | import uuid 7 | from optparse import OptionParser 8 | 9 | import aiohttp 10 | 11 | from ms_tournament.base import MSRPCChannel 12 | from ms_tournament.rpc import CustomizedContestManagerApi 13 | import ms_tournament.protocol_admin_pb2 as pb 14 | 15 | 16 | logging.basicConfig( 17 | level=logging.INFO, format="%(asctime)s %(levelname)s: %(message)s", datefmt="%Y-%m-%d %H:%M:%S" 18 | ) 19 | 20 | MS_HOST = "https://mahjongsoul.tournament.yo-star.com" 21 | MS_MANAGER_API_URL = "https://mjusgs.mahjongsoul.com:7988" 22 | 23 | async def main(): 24 | """ 25 | Login to the EN server with OAuth2 access token and get tournament list. 26 | """ 27 | parser = OptionParser() 28 | parser.add_option("-t", "--token", type="string", help="Access token for connect.") 29 | 30 | opts, _ = parser.parse_args() 31 | access_token = opts.token 32 | 33 | if not access_token: 34 | parser.error("Access token cant be empty") 35 | 36 | manager_api, channel = await connect() 37 | await login(manager_api, access_token) 38 | await load_tournaments_list(manager_api) 39 | await channel.close() 40 | 41 | 42 | async def connect(): 43 | async with aiohttp.ClientSession() as session: 44 | async with session.get("{}/api/customized_contest/random".format(MS_MANAGER_API_URL)) as res: 45 | servers = await res.json() 46 | endpoint_gate = servers['servers'][0] 47 | endpoint = "wss://{}/".format(endpoint_gate) 48 | 49 | logging.info(f"Chosen endpoint: {endpoint}") 50 | channel = MSRPCChannel(endpoint) 51 | 52 | manager_api = CustomizedContestManagerApi(channel) 53 | 54 | await channel.connect(MS_HOST) 55 | logging.info("Connection was established") 56 | 57 | return manager_api, channel 58 | 59 | 60 | async def login(manager_api, access_token): 61 | logging.info("") 62 | logging.info("Login with OAuth2 access token to manager panel") 63 | 64 | req = pb.ReqContestManageOauth2Login() 65 | req.type = 7 66 | req.access_token = access_token 67 | req.reconnect = False 68 | 69 | res = await manager_api.oauth2_login_contest_manager(req) 70 | token = res.access_token 71 | nickname = res.nickname 72 | account_id = res.account_id 73 | if not token: 74 | logging.error("Login Error:") 75 | logging.error(res) 76 | return False 77 | logging.info("Login succesfull!") 78 | logging.info("###################################################") 79 | logging.info(f"access token: {token}") 80 | logging.info(f"account_id: {account_id}") 81 | logging.info(f"nickname: {nickname}") 82 | logging.info("###################################################") 83 | logging.info("") 84 | return True 85 | 86 | async def load_tournaments_list(manager_api): 87 | logging.info("Loading tournament list...") 88 | 89 | req = pb.ReqCommon() 90 | res = await manager_api.fetch_related_contest_list(req) 91 | tournaments_count = len(res.contests) 92 | logging.info(f"found tournaments : {tournaments_count}") 93 | 94 | for i in range(0, tournaments_count): 95 | logging.info("") 96 | logging.info(f"unique_id: {res.contests[i].unique_id}") 97 | logging.info(f"contest_id: {res.contests[i].contest_id}") 98 | logging.info(f"contest_name: {res.contests[i].contest_name}") 99 | 100 | return True 101 | 102 | if __name__ == "__main__": 103 | asyncio.run(main()) 104 | -------------------------------------------------------------------------------- /ms/.tool-versions: -------------------------------------------------------------------------------- 1 | protoc 22.3 2 | -------------------------------------------------------------------------------- /ms/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MahjongRepository/mahjong_soul_api/314c6c935d60bb788084fc60c30df42661543434/ms/__init__.py -------------------------------------------------------------------------------- /ms/base.py: -------------------------------------------------------------------------------- 1 | import asyncio 2 | import websockets 3 | 4 | from ms.protocol_pb2 import Wrapper 5 | 6 | 7 | class MSRPCChannel: 8 | 9 | def __init__(self, endpoint): 10 | self._endpoint = endpoint 11 | self._req_events = {} 12 | self._new_req_idx = 1 13 | self._res = {} 14 | self._hooks = {} 15 | 16 | self._ws = None 17 | self._msg_dispatcher = None 18 | 19 | def add_hook(self, msg_type, hook): 20 | if msg_type not in self._hooks: 21 | self._hooks[msg_type] = [] 22 | self._hooks[msg_type].append(hook) 23 | 24 | def unwrap(self, wrapped): 25 | wrapper = Wrapper() 26 | wrapper.ParseFromString(wrapped) 27 | return wrapper 28 | 29 | def wrap(self, name, data): 30 | wrapper = Wrapper() 31 | wrapper.name = name 32 | wrapper.data = data 33 | return wrapper.SerializeToString() 34 | 35 | async def connect(self, ms_host): 36 | self._ws = await websockets.connect(self._endpoint, origin=ms_host) 37 | self._msg_dispatcher = asyncio.create_task(self.dispatch_msg()) 38 | 39 | async def close(self): 40 | self._msg_dispatcher.cancel() 41 | try: 42 | await self._msg_dispatcher 43 | except asyncio.CancelledError: 44 | pass 45 | finally: 46 | await self._ws.close() 47 | 48 | async def dispatch_msg(self): 49 | while True: 50 | msg = await self._ws.recv() 51 | type_byte = msg[0] 52 | if type_byte == 1: # NOTIFY 53 | wrapper = self.unwrap(msg[1:]) 54 | for hook in self._hooks.get(wrapper.name, []): 55 | asyncio.create_task(hook(wrapper.data)) 56 | elif type_byte == 2: # REQUEST 57 | wrapper = self.unwrap(msg[3:]) 58 | for hook in self._hooks.get(wrapper.name, []): 59 | asyncio.create_task(hook(wrapper.data)) 60 | elif type_byte == 3: # RESPONSE 61 | idx = int.from_bytes(msg[1:3], 'little') 62 | if not idx in self._req_events: 63 | continue 64 | self._res[idx] = msg 65 | self._req_events[idx].set() 66 | 67 | async def send_request(self, name, msg): 68 | idx = self._new_req_idx 69 | self._new_req_idx = (self._new_req_idx + 1) % 60007 70 | 71 | wrapped = self.wrap(name, msg) 72 | pkt = b'\x02' + idx.to_bytes(2, 'little') + wrapped 73 | 74 | evt = asyncio.Event() 75 | self._req_events[idx] = evt 76 | 77 | await self._ws.send(pkt) 78 | await evt.wait() 79 | 80 | if not idx in self._res: 81 | return None 82 | res = self._res[idx] 83 | del self._res[idx] 84 | 85 | if idx in self._req_events: 86 | del self._req_events[idx] 87 | 88 | body = self.unwrap(res[3:]) 89 | 90 | return body.data 91 | 92 | 93 | class MSRPCService: 94 | 95 | def __init__(self, channel): 96 | self._channel = channel 97 | 98 | def get_package_name(self): 99 | raise NotImplementedError 100 | 101 | def get_service_name(self): 102 | raise NotImplementedError 103 | 104 | def get_req_class(self, method): 105 | raise NotImplementedError 106 | 107 | def get_res_class(self, method): 108 | raise NotImplementedError 109 | 110 | async def call_method(self, method, req): 111 | msg = req.SerializeToString() 112 | name = '.{}.{}.{}'.format(self.get_package_name(), self.get_service_name(), method) 113 | res_msg = await self._channel.send_request(name, msg) 114 | res_class = self.get_res_class(method) 115 | res = res_class() 116 | res.ParseFromString(res_msg) 117 | return res 118 | -------------------------------------------------------------------------------- /ms/generate_proto_file.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | import json 3 | from collections import OrderedDict 4 | from io import StringIO 5 | from pprint import pprint 6 | 7 | filename = 'liqi.json' 8 | data = json.load(open(filename), object_pairs_hook=OrderedDict) 9 | buf = StringIO() 10 | buf.write('syntax = "proto3";\n\n') 11 | 12 | data = data['nested'] 13 | assert len(data) == 1 14 | package_name = list(data.keys())[0] 15 | buf.write('package {};\n\n'.format(package_name)) 16 | data = data[package_name] 17 | data = data['nested'] 18 | 19 | indent = 0 20 | 21 | 22 | def write_line(line=''): 23 | buf.write('{}{}\n'.format(' ' * 2 * indent, line)) 24 | 25 | 26 | def parse_fields(fields): 27 | for name in fields: 28 | if 'rule' in fields[name]: 29 | rule = fields[name]['rule'] + ' ' 30 | else: 31 | rule = '' 32 | write_line('{}{} {} = {};'.format(rule, fields[name]['type'], name, fields[name]['id'])) 33 | 34 | 35 | def parse_methods(methods): 36 | for name in methods: 37 | write_line( 38 | 'rpc {} ({}) returns ({});'.format(name, methods[name]['requestType'], methods[name]['responseType'])) 39 | 40 | 41 | def parse_values(values): 42 | for name in values: 43 | write_line('{} = {};'.format(name, values[name])) 44 | 45 | 46 | def parse_item(name, item): 47 | global indent 48 | if 'fields' in item: 49 | write_line('message {} {{'.format(name)) 50 | indent += 1 51 | parse_fields(item['fields']) 52 | elif 'methods' in item: 53 | write_line('service {} {{'.format(name)) 54 | indent += 1 55 | parse_methods(item['methods']) 56 | elif 'values' in item: 57 | write_line('enum {} {{'.format(name)) 58 | indent += 1 59 | parse_values(item['values']) 60 | else: 61 | pprint(item) 62 | raise Exception('Unrecognized Item') 63 | if 'nested' in item: 64 | assert len(item) == 2 65 | nested = item['nested'] 66 | for child in nested: 67 | parse_item(child, nested[child]) 68 | 69 | indent -= 1 70 | write_line('}\n') 71 | 72 | 73 | for name in data: 74 | parse_item(name, data[name]) 75 | 76 | with open('protocol.proto', 'w') as f: 77 | f.write(buf.getvalue()) 78 | -------------------------------------------------------------------------------- /ms/ms-plugin.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | import re 3 | import sys 4 | 5 | from google.protobuf.compiler import plugin_pb2 as plugin 6 | 7 | header = '''# -*- coding: utf-8 -*- 8 | # Generated. DO NOT EDIT! 9 | 10 | import ms.protocol_pb2 as pb 11 | from ms.base import MSRPCService 12 | ''' 13 | 14 | cls_tplt = ''' 15 | class {class_name}(MSRPCService): 16 | version = None 17 | 18 | _req = {{ 19 | {req_list} 20 | }} 21 | _res = {{ 22 | {res_list} 23 | }} 24 | 25 | def get_package_name(self): 26 | return '{package_name}' 27 | 28 | def get_service_name(self): 29 | return '{class_name}' 30 | 31 | def get_req_class(self, method): 32 | return {class_name}._req[method] 33 | 34 | def get_res_class(self, method): 35 | return {class_name}._res[method] 36 | {func_list} 37 | ''' 38 | 39 | dict_template = ' \'{method_name}\': pb.{type_name},' 40 | 41 | func_template = ''' 42 | async def {func_name}(self, req): 43 | return await self.call_method('{method_name}', req)''' 44 | 45 | 46 | def to_snake_case(name): 47 | s1 = re.sub('(.)([A-Z][a-z]+)', r'\1_\2', name) 48 | return re.sub('([a-z0-9])([A-Z])', r'\1_\2', s1).lower() 49 | 50 | 51 | def generate_code(request, response): 52 | for proto_file in request.proto_file: 53 | package_name = proto_file.package 54 | 55 | services = [] 56 | for srv in proto_file.service: 57 | class_name = srv.name 58 | req_list = [] 59 | res_list = [] 60 | func_list = [] 61 | for mtd in srv.method: 62 | method_name = mtd.name 63 | func_name = to_snake_case(method_name) 64 | 65 | req_name = mtd.input_type.rsplit('.', 1)[-1] 66 | res_name = mtd.output_type.rsplit('.', 1)[-1] 67 | req_list.append(dict_template.format(method_name=method_name, type_name=req_name)) 68 | res_list.append(dict_template.format(method_name=method_name, type_name=res_name)) 69 | func_list.append(func_template.format(method_name=method_name, func_name=func_name)) 70 | 71 | cls = cls_tplt.format(package_name=package_name, 72 | class_name=class_name, 73 | req_list='\n'.join(req_list), 74 | res_list='\n'.join(res_list), 75 | func_list='\n'.join(func_list)) 76 | services.append(cls) 77 | 78 | body = '\n'.join(services) 79 | src = header + '\n' + body 80 | f = response.file.add() 81 | f.name = 'rpc.py' 82 | f.content = src 83 | 84 | 85 | if __name__ == '__main__': 86 | # Read request message from stdin 87 | data = sys.stdin.buffer.read() 88 | 89 | # Parse request 90 | request = plugin.CodeGeneratorRequest() 91 | request.ParseFromString(data) 92 | 93 | # Create response 94 | response = plugin.CodeGeneratorResponse() 95 | 96 | # Generate code 97 | generate_code(request, response) 98 | 99 | # Serialise response message 100 | output = response.SerializeToString() 101 | 102 | # Write to stdout 103 | sys.stdout.buffer.write(output) 104 | -------------------------------------------------------------------------------- /ms/rpc.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | # Generated. DO NOT EDIT! 3 | 4 | import ms.protocol_pb2 as pb 5 | from ms.base import MSRPCService 6 | 7 | 8 | class Lobby(MSRPCService): 9 | version = None 10 | 11 | _req = { 12 | 'fetchConnectionInfo': pb.ReqCommon, 13 | 'fetchQueueInfo': pb.ReqCommon, 14 | 'cancelQueue': pb.ReqCommon, 15 | 'openidCheck': pb.ReqOpenidCheck, 16 | 'signup': pb.ReqSignupAccount, 17 | 'login': pb.ReqLogin, 18 | 'loginSuccess': pb.ReqCommon, 19 | 'emailLogin': pb.ReqEmailLogin, 20 | 'oauth2Auth': pb.ReqOauth2Auth, 21 | 'oauth2Check': pb.ReqOauth2Check, 22 | 'oauth2Signup': pb.ReqOauth2Signup, 23 | 'oauth2Login': pb.ReqOauth2Login, 24 | 'dmmPreLogin': pb.ReqDMMPreLogin, 25 | 'createPhoneVerifyCode': pb.ReqCreatePhoneVerifyCode, 26 | 'createEmailVerifyCode': pb.ReqCreateEmailVerifyCode, 27 | 'verfifyCodeForSecure': pb.ReqVerifyCodeForSecure, 28 | 'bindPhoneNumber': pb.ReqBindPhoneNumber, 29 | 'unbindPhoneNumber': pb.ReqUnbindPhoneNumber, 30 | 'fetchPhoneLoginBind': pb.ReqCommon, 31 | 'createPhoneLoginBind': pb.ReqCreatePhoneLoginBind, 32 | 'bindEmail': pb.ReqBindEmail, 33 | 'modifyPassword': pb.ReqModifyPassword, 34 | 'bindAccount': pb.ReqBindAccount, 35 | 'logout': pb.ReqLogout, 36 | 'heatbeat': pb.ReqHeatBeat, 37 | 'loginBeat': pb.ReqLoginBeat, 38 | 'createNickname': pb.ReqCreateNickname, 39 | 'modifyNickname': pb.ReqModifyNickname, 40 | 'modifyBirthday': pb.ReqModifyBirthday, 41 | 'fetchRoom': pb.ReqCommon, 42 | 'createRoom': pb.ReqCreateRoom, 43 | 'joinRoom': pb.ReqJoinRoom, 44 | 'leaveRoom': pb.ReqCommon, 45 | 'readyPlay': pb.ReqRoomReady, 46 | 'dressingStatus': pb.ReqRoomDressing, 47 | 'startRoom': pb.ReqRoomStart, 48 | 'kickPlayer': pb.ReqRoomKick, 49 | 'modifyRoom': pb.ReqModifyRoom, 50 | 'matchGame': pb.ReqJoinMatchQueue, 51 | 'cancelMatch': pb.ReqCancelMatchQueue, 52 | 'fetchAccountInfo': pb.ReqAccountInfo, 53 | 'changeAvatar': pb.ReqChangeAvatar, 54 | 'receiveVersionReward': pb.ReqCommon, 55 | 'fetchAccountStatisticInfo': pb.ReqAccountStatisticInfo, 56 | 'fetchAccountChallengeRankInfo': pb.ReqAccountInfo, 57 | 'fetchAccountCharacterInfo': pb.ReqCommon, 58 | 'shopPurchase': pb.ReqShopPurchase, 59 | 'fetchGameRecord': pb.ReqGameRecord, 60 | 'readGameRecord': pb.ReqGameRecord, 61 | 'fetchGameRecordList': pb.ReqGameRecordList, 62 | 'fetchCollectedGameRecordList': pb.ReqCommon, 63 | 'fetchGameRecordsDetail': pb.ReqGameRecordsDetail, 64 | 'addCollectedGameRecord': pb.ReqAddCollectedGameRecord, 65 | 'removeCollectedGameRecord': pb.ReqRemoveCollectedGameRecord, 66 | 'changeCollectedGameRecordRemarks': pb.ReqChangeCollectedGameRecordRemarks, 67 | 'fetchLevelLeaderboard': pb.ReqLevelLeaderboard, 68 | 'fetchChallengeLeaderboard': pb.ReqChallangeLeaderboard, 69 | 'fetchMutiChallengeLevel': pb.ReqMutiChallengeLevel, 70 | 'fetchMultiAccountBrief': pb.ReqMultiAccountId, 71 | 'fetchFriendList': pb.ReqCommon, 72 | 'fetchFriendApplyList': pb.ReqCommon, 73 | 'applyFriend': pb.ReqApplyFriend, 74 | 'handleFriendApply': pb.ReqHandleFriendApply, 75 | 'removeFriend': pb.ReqRemoveFriend, 76 | 'searchAccountById': pb.ReqSearchAccountById, 77 | 'searchAccountByPattern': pb.ReqSearchAccountByPattern, 78 | 'fetchAccountState': pb.ReqAccountList, 79 | 'fetchBagInfo': pb.ReqCommon, 80 | 'useBagItem': pb.ReqUseBagItem, 81 | 'openManualItem': pb.ReqOpenManualItem, 82 | 'openRandomRewardItem': pb.ReqOpenRandomRewardItem, 83 | 'openAllRewardItem': pb.ReqOpenAllRewardItem, 84 | 'composeShard': pb.ReqComposeShard, 85 | 'fetchAnnouncement': pb.ReqFetchAnnouncement, 86 | 'readAnnouncement': pb.ReqReadAnnouncement, 87 | 'fetchMailInfo': pb.ReqCommon, 88 | 'readMail': pb.ReqReadMail, 89 | 'deleteMail': pb.ReqDeleteMail, 90 | 'takeAttachmentFromMail': pb.ReqTakeAttachment, 91 | 'receiveAchievementReward': pb.ReqReceiveAchievementReward, 92 | 'receiveAchievementGroupReward': pb.ReqReceiveAchievementGroupReward, 93 | 'fetchAchievementRate': pb.ReqCommon, 94 | 'fetchAchievement': pb.ReqCommon, 95 | 'buyShiLian': pb.ReqBuyShiLian, 96 | 'matchShiLian': pb.ReqCommon, 97 | 'goNextShiLian': pb.ReqCommon, 98 | 'updateClientValue': pb.ReqUpdateClientValue, 99 | 'fetchClientValue': pb.ReqCommon, 100 | 'clientMessage': pb.ReqClientMessage, 101 | 'fetchCurrentMatchInfo': pb.ReqCurrentMatchInfo, 102 | 'userComplain': pb.ReqUserComplain, 103 | 'fetchReviveCoinInfo': pb.ReqCommon, 104 | 'gainReviveCoin': pb.ReqCommon, 105 | 'fetchDailyTask': pb.ReqCommon, 106 | 'refreshDailyTask': pb.ReqRefreshDailyTask, 107 | 'useGiftCode': pb.ReqUseGiftCode, 108 | 'useSpecialGiftCode': pb.ReqUseGiftCode, 109 | 'fetchTitleList': pb.ReqCommon, 110 | 'useTitle': pb.ReqUseTitle, 111 | 'sendClientMessage': pb.ReqSendClientMessage, 112 | 'fetchGameLiveInfo': pb.ReqGameLiveInfo, 113 | 'fetchGameLiveLeftSegment': pb.ReqGameLiveLeftSegment, 114 | 'fetchGameLiveList': pb.ReqGameLiveList, 115 | 'fetchCommentSetting': pb.ReqCommon, 116 | 'updateCommentSetting': pb.ReqUpdateCommentSetting, 117 | 'fetchCommentList': pb.ReqFetchCommentList, 118 | 'fetchCommentContent': pb.ReqFetchCommentContent, 119 | 'leaveComment': pb.ReqLeaveComment, 120 | 'deleteComment': pb.ReqDeleteComment, 121 | 'updateReadComment': pb.ReqUpdateReadComment, 122 | 'fetchRollingNotice': pb.ReqCommon, 123 | 'fetchServerTime': pb.ReqCommon, 124 | 'fetchPlatformProducts': pb.ReqPlatformBillingProducts, 125 | 'cancelGooglePlayOrder': pb.ReqCancelGooglePlayOrder, 126 | 'openChest': pb.ReqOpenChest, 127 | 'buyFromChestShop': pb.ReqBuyFromChestShop, 128 | 'fetchDailySignInInfo': pb.ReqCommon, 129 | 'doDailySignIn': pb.ReqCommon, 130 | 'doActivitySignIn': pb.ReqDoActivitySignIn, 131 | 'fetchCharacterInfo': pb.ReqCommon, 132 | 'updateCharacterSort': pb.ReqUpdateCharacterSort, 133 | 'changeMainCharacter': pb.ReqChangeMainCharacter, 134 | 'changeCharacterSkin': pb.ReqChangeCharacterSkin, 135 | 'changeCharacterView': pb.ReqChangeCharacterView, 136 | 'setHiddenCharacter': pb.ReqSetHiddenCharacter, 137 | 'sendGiftToCharacter': pb.ReqSendGiftToCharacter, 138 | 'sellItem': pb.ReqSellItem, 139 | 'fetchCommonView': pb.ReqCommon, 140 | 'changeCommonView': pb.ReqChangeCommonView, 141 | 'saveCommonViews': pb.ReqSaveCommonViews, 142 | 'fetchCommonViews': pb.ReqCommonViews, 143 | 'fetchAllCommonViews': pb.ReqCommon, 144 | 'useCommonView': pb.ReqUseCommonView, 145 | 'upgradeCharacter': pb.ReqUpgradeCharacter, 146 | 'addFinishedEnding': pb.ReqFinishedEnding, 147 | 'receiveEndingReward': pb.ReqFinishedEnding, 148 | 'gameMasterCommand': pb.ReqGMCommand, 149 | 'fetchShopInfo': pb.ReqCommon, 150 | 'buyFromShop': pb.ReqBuyFromShop, 151 | 'buyFromZHP': pb.ReqBuyFromZHP, 152 | 'refreshZHPShop': pb.ReqReshZHPShop, 153 | 'fetchMonthTicketInfo': pb.ReqCommon, 154 | 'payMonthTicket': pb.ReqCommon, 155 | 'exchangeCurrency': pb.ReqExchangeCurrency, 156 | 'exchangeChestStone': pb.ReqExchangeCurrency, 157 | 'exchangeDiamond': pb.ReqExchangeCurrency, 158 | 'fetchServerSettings': pb.ReqCommon, 159 | 'fetchAccountSettings': pb.ReqCommon, 160 | 'updateAccountSettings': pb.ReqUpdateAccountSettings, 161 | 'fetchModNicknameTime': pb.ReqCommon, 162 | 'createWechatNativeOrder': pb.ReqCreateWechatNativeOrder, 163 | 'createWechatAppOrder': pb.ReqCreateWechatAppOrder, 164 | 'createAlipayOrder': pb.ReqCreateAlipayOrder, 165 | 'createAlipayScanOrder': pb.ReqCreateAlipayScanOrder, 166 | 'createAlipayAppOrder': pb.ReqCreateAlipayAppOrder, 167 | 'createJPCreditCardOrder': pb.ReqCreateJPCreditCardOrder, 168 | 'createJPPaypalOrder': pb.ReqCreateJPPaypalOrder, 169 | 'createJPAuOrder': pb.ReqCreateJPAuOrder, 170 | 'createJPDocomoOrder': pb.ReqCreateJPDocomoOrder, 171 | 'createJPWebMoneyOrder': pb.ReqCreateJPWebMoneyOrder, 172 | 'createJPSoftbankOrder': pb.ReqCreateJPSoftbankOrder, 173 | 'createJPPayPayOrder': pb.ReqCreateJPPayPayOrder, 174 | 'fetchJPCommonCreditCardOrder': pb.ReqFetchJPCommonCreditCardOrder, 175 | 'createJPGMOOrder': pb.ReqCreateJPGMOOrder, 176 | 'createENPaypalOrder': pb.ReqCreateENPaypalOrder, 177 | 'createENMasterCardOrder': pb.ReqCreateENMasterCardOrder, 178 | 'createENVisaOrder': pb.ReqCreateENVisaOrder, 179 | 'createENJCBOrder': pb.ReqCreateENJCBOrder, 180 | 'createENAlipayOrder': pb.ReqCreateENAlipayOrder, 181 | 'createKRPaypalOrder': pb.ReqCreateKRPaypalOrder, 182 | 'createKRMasterCardOrder': pb.ReqCreateKRMasterCardOrder, 183 | 'createKRVisaOrder': pb.ReqCreateKRVisaOrder, 184 | 'createKRJCBOrder': pb.ReqCreateKRJCBOrder, 185 | 'createKRAlipayOrder': pb.ReqCreateKRAlipayOrder, 186 | 'createDMMOrder': pb.ReqCreateDMMOrder, 187 | 'createIAPOrder': pb.ReqCreateIAPOrder, 188 | 'createSteamOrder': pb.ReqCreateSteamOrder, 189 | 'verifySteamOrder': pb.ReqVerifySteamOrder, 190 | 'createMyCardAndroidOrder': pb.ReqCreateMyCardOrder, 191 | 'createMyCardWebOrder': pb.ReqCreateMyCardOrder, 192 | 'createPaypalOrder': pb.ReqCreatePaypalOrder, 193 | 'createXsollaOrder': pb.ReqCreateXsollaOrder, 194 | 'verifyMyCardOrder': pb.ReqVerifyMyCardOrder, 195 | 'verificationIAPOrder': pb.ReqVerificationIAPOrder, 196 | 'createYostarSDKOrder': pb.ReqCreateYostarOrder, 197 | 'createBillingOrder': pb.ReqCreateBillingOrder, 198 | 'solveGooglePlayOrder': pb.ReqSolveGooglePlayOrder, 199 | 'solveGooglePayOrderV3': pb.ReqSolveGooglePlayOrderV3, 200 | 'deliverAA32Order': pb.ReqDeliverAA32Order, 201 | 'fetchMisc': pb.ReqCommon, 202 | 'modifySignature': pb.ReqModifySignature, 203 | 'fetchIDCardInfo': pb.ReqCommon, 204 | 'updateIDCardInfo': pb.ReqUpdateIDCardInfo, 205 | 'fetchVipReward': pb.ReqCommon, 206 | 'gainVipReward': pb.ReqGainVipReward, 207 | 'fetchRefundOrder': pb.ReqCommon, 208 | 'fetchCustomizedContestList': pb.ReqFetchCustomizedContestList, 209 | 'fetchCustomizedContestExtendInfo': pb.ReqFetchCustomizedContestExtendInfo, 210 | 'fetchCustomizedContestAuthInfo': pb.ReqFetchCustomizedContestAuthInfo, 211 | 'enterCustomizedContest': pb.ReqEnterCustomizedContest, 212 | 'leaveCustomizedContest': pb.ReqCommon, 213 | 'fetchCustomizedContestOnlineInfo': pb.ReqFetchCustomizedContestOnlineInfo, 214 | 'fetchCustomizedContestByContestId': pb.ReqFetchCustomizedContestByContestId, 215 | 'startCustomizedContest': pb.ReqStartCustomizedContest, 216 | 'stopCustomizedContest': pb.ReqCommon, 217 | 'joinCustomizedContestChatRoom': pb.ReqJoinCustomizedContestChatRoom, 218 | 'leaveCustomizedContestChatRoom': pb.ReqCommon, 219 | 'sayChatMessage': pb.ReqSayChatMessage, 220 | 'fetchCustomizedContestGameRecords': pb.ReqFetchCustomizedContestGameRecords, 221 | 'fetchCustomizedContestGameLiveList': pb.ReqFetchCustomizedContestGameLiveList, 222 | 'followCustomizedContest': pb.ReqTargetCustomizedContest, 223 | 'unfollowCustomizedContest': pb.ReqTargetCustomizedContest, 224 | 'fetchActivityList': pb.ReqCommon, 225 | 'fetchAccountActivityData': pb.ReqCommon, 226 | 'exchangeActivityItem': pb.ReqExchangeActivityItem, 227 | 'completeActivityTask': pb.ReqCompleteActivityTask, 228 | 'completeActivityFlipTask': pb.ReqCompleteActivityTask, 229 | 'completePeriodActivityTask': pb.ReqCompleteActivityTask, 230 | 'completePeriodActivityTaskBatch': pb.ReqCompletePeriodActivityTaskBatch, 231 | 'completeRandomActivityTask': pb.ReqCompleteActivityTask, 232 | 'receiveActivityFlipTask': pb.ReqReceiveActivityFlipTask, 233 | 'completeSegmentTaskReward': pb.ReqCompleteSegmentTaskReward, 234 | 'fetchActivityFlipInfo': pb.ReqFetchActivityFlipInfo, 235 | 'gainAccumulatedPointActivityReward': pb.ReqGainAccumulatedPointActivityReward, 236 | 'gainMultiPointActivityReward': pb.ReqGainMultiPointActivityReward, 237 | 'fetchRankPointLeaderboard': pb.ReqFetchRankPointLeaderboard, 238 | 'gainRankPointReward': pb.ReqGainRankPointReward, 239 | 'richmanActivityNextMove': pb.ReqRichmanNextMove, 240 | 'richmanAcitivitySpecialMove': pb.ReqRichmanSpecialMove, 241 | 'richmanActivityChestInfo': pb.ReqRichmanChestInfo, 242 | 'createGameObserveAuth': pb.ReqCreateGameObserveAuth, 243 | 'refreshGameObserveAuth': pb.ReqRefreshGameObserveAuth, 244 | 'fetchActivityBuff': pb.ReqCommon, 245 | 'upgradeActivityBuff': pb.ReqUpgradeActivityBuff, 246 | 'upgradeActivityLevel': pb.ReqUpgradeActivityLevel, 247 | 'receiveUpgradeActivityReward': pb.ReqReceiveUpgradeActivityReward, 248 | 'upgradeChallenge': pb.ReqCommon, 249 | 'refreshChallenge': pb.ReqCommon, 250 | 'fetchChallengeInfo': pb.ReqCommon, 251 | 'forceCompleteChallengeTask': pb.ReqForceCompleteChallengeTask, 252 | 'fetchChallengeSeason': pb.ReqCommon, 253 | 'receiveChallengeRankReward': pb.ReqReceiveChallengeRankReward, 254 | 'fetchABMatchInfo': pb.ReqCommon, 255 | 'buyInABMatch': pb.ReqBuyInABMatch, 256 | 'receiveABMatchReward': pb.ReqCommon, 257 | 'quitABMatch': pb.ReqCommon, 258 | 'startUnifiedMatch': pb.ReqStartUnifiedMatch, 259 | 'cancelUnifiedMatch': pb.ReqCancelUnifiedMatch, 260 | 'fetchGamePointRank': pb.ReqGamePointRank, 261 | 'fetchSelfGamePointRank': pb.ReqGamePointRank, 262 | 'readSNS': pb.ReqReadSNS, 263 | 'replySNS': pb.ReqReplySNS, 264 | 'likeSNS': pb.ReqLikeSNS, 265 | 'digMine': pb.ReqDigMine, 266 | 'fetchLastPrivacy': pb.ReqFetchLastPrivacy, 267 | 'checkPrivacy': pb.ReqCheckPrivacy, 268 | 'responseCaptcha': pb.ReqResponseCaptcha, 269 | 'fetchRPGBattleHistory': pb.ReqFetchRPGBattleHistory, 270 | 'fetchRPGBattleHistoryV2': pb.ReqFetchRPGBattleHistory, 271 | 'receiveRPGRewards': pb.ReqReceiveRPGRewards, 272 | 'receiveRPGReward': pb.ReqReceiveRPGReward, 273 | 'buyArenaTicket': pb.ReqBuyArenaTicket, 274 | 'enterArena': pb.ReqEnterArena, 275 | 'receiveArenaReward': pb.ReqArenaReward, 276 | 'fetchOBToken': pb.ReqFetchOBToken, 277 | 'receiveCharacterRewards': pb.ReqReceiveCharacterRewards, 278 | 'feedActivityFeed': pb.ReqFeedActivityFeed, 279 | 'sendActivityGiftToFriend': pb.ReqSendActivityGiftToFriend, 280 | 'receiveActivityGift': pb.ReqReceiveActivityGift, 281 | 'receiveAllActivityGift': pb.ReqReceiveAllActivityGift, 282 | 'fetchFriendGiftActivityData': pb.ReqFetchFriendGiftActivityData, 283 | 'openPreChestItem': pb.ReqOpenPreChestItem, 284 | 'fetchVoteActivity': pb.ReqFetchVoteActivity, 285 | 'voteActivity': pb.ReqVoteActivity, 286 | 'unlockActivitySpot': pb.ReqUnlockActivitySpot, 287 | 'unlockActivitySpotEnding': pb.ReqUnlockActivitySpotEnding, 288 | 'receiveActivitySpotReward': pb.ReqReceiveActivitySpotReward, 289 | 'deleteAccount': pb.ReqCommon, 290 | 'cancelDeleteAccount': pb.ReqCommon, 291 | 'logReport': pb.ReqLogReport, 292 | 'bindOauth2': pb.ReqBindOauth2, 293 | 'fetchOauth2Info': pb.ReqFetchOauth2, 294 | 'setLoadingImage': pb.ReqSetLoadingImage, 295 | 'fetchShopInterval': pb.ReqCommon, 296 | 'fetchActivityInterval': pb.ReqCommon, 297 | 'fetchRecentFriend': pb.ReqCommon, 298 | 'openGacha': pb.ReqOpenGacha, 299 | 'taskRequest': pb.ReqTaskRequest, 300 | 'simulationActivityTrain': pb.ReqSimulationActivityTrain, 301 | 'fetchSimulationGameRecord': pb.ReqFetchSimulationGameRecord, 302 | 'startSimulationActivityGame': pb.ReqStartSimulationActivityGame, 303 | 'fetchSimulationGameRank': pb.ReqFetchSimulationGameRank, 304 | } 305 | _res = { 306 | 'fetchConnectionInfo': pb.ResConnectionInfo, 307 | 'fetchQueueInfo': pb.ResFetchQueueInfo, 308 | 'cancelQueue': pb.ResCommon, 309 | 'openidCheck': pb.ResOauth2Check, 310 | 'signup': pb.ResSignupAccount, 311 | 'login': pb.ResLogin, 312 | 'loginSuccess': pb.ResCommon, 313 | 'emailLogin': pb.ResLogin, 314 | 'oauth2Auth': pb.ResOauth2Auth, 315 | 'oauth2Check': pb.ResOauth2Check, 316 | 'oauth2Signup': pb.ResOauth2Signup, 317 | 'oauth2Login': pb.ResLogin, 318 | 'dmmPreLogin': pb.ResDMMPreLogin, 319 | 'createPhoneVerifyCode': pb.ResCommon, 320 | 'createEmailVerifyCode': pb.ResCommon, 321 | 'verfifyCodeForSecure': pb.ResVerfiyCodeForSecure, 322 | 'bindPhoneNumber': pb.ResCommon, 323 | 'unbindPhoneNumber': pb.ResCommon, 324 | 'fetchPhoneLoginBind': pb.ResFetchPhoneLoginBind, 325 | 'createPhoneLoginBind': pb.ResCommon, 326 | 'bindEmail': pb.ResCommon, 327 | 'modifyPassword': pb.ResCommon, 328 | 'bindAccount': pb.ResCommon, 329 | 'logout': pb.ResLogout, 330 | 'heatbeat': pb.ResCommon, 331 | 'loginBeat': pb.ResCommon, 332 | 'createNickname': pb.ResCommon, 333 | 'modifyNickname': pb.ResCommon, 334 | 'modifyBirthday': pb.ResCommon, 335 | 'fetchRoom': pb.ResSelfRoom, 336 | 'createRoom': pb.ResCreateRoom, 337 | 'joinRoom': pb.ResJoinRoom, 338 | 'leaveRoom': pb.ResCommon, 339 | 'readyPlay': pb.ResCommon, 340 | 'dressingStatus': pb.ResCommon, 341 | 'startRoom': pb.ResCommon, 342 | 'kickPlayer': pb.ResCommon, 343 | 'modifyRoom': pb.ResCommon, 344 | 'matchGame': pb.ResCommon, 345 | 'cancelMatch': pb.ResCommon, 346 | 'fetchAccountInfo': pb.ResAccountInfo, 347 | 'changeAvatar': pb.ResCommon, 348 | 'receiveVersionReward': pb.ResCommon, 349 | 'fetchAccountStatisticInfo': pb.ResAccountStatisticInfo, 350 | 'fetchAccountChallengeRankInfo': pb.ResAccountChallengeRankInfo, 351 | 'fetchAccountCharacterInfo': pb.ResAccountCharacterInfo, 352 | 'shopPurchase': pb.ResShopPurchase, 353 | 'fetchGameRecord': pb.ResGameRecord, 354 | 'readGameRecord': pb.ResCommon, 355 | 'fetchGameRecordList': pb.ResGameRecordList, 356 | 'fetchCollectedGameRecordList': pb.ResCollectedGameRecordList, 357 | 'fetchGameRecordsDetail': pb.ResGameRecordsDetail, 358 | 'addCollectedGameRecord': pb.ResAddCollectedGameRecord, 359 | 'removeCollectedGameRecord': pb.ResRemoveCollectedGameRecord, 360 | 'changeCollectedGameRecordRemarks': pb.ResChangeCollectedGameRecordRemarks, 361 | 'fetchLevelLeaderboard': pb.ResLevelLeaderboard, 362 | 'fetchChallengeLeaderboard': pb.ResChallengeLeaderboard, 363 | 'fetchMutiChallengeLevel': pb.ResMutiChallengeLevel, 364 | 'fetchMultiAccountBrief': pb.ResMultiAccountBrief, 365 | 'fetchFriendList': pb.ResFriendList, 366 | 'fetchFriendApplyList': pb.ResFriendApplyList, 367 | 'applyFriend': pb.ResCommon, 368 | 'handleFriendApply': pb.ResCommon, 369 | 'removeFriend': pb.ResCommon, 370 | 'searchAccountById': pb.ResSearchAccountById, 371 | 'searchAccountByPattern': pb.ResSearchAccountByPattern, 372 | 'fetchAccountState': pb.ResAccountStates, 373 | 'fetchBagInfo': pb.ResBagInfo, 374 | 'useBagItem': pb.ResCommon, 375 | 'openManualItem': pb.ResCommon, 376 | 'openRandomRewardItem': pb.ResOpenRandomRewardItem, 377 | 'openAllRewardItem': pb.ResOpenAllRewardItem, 378 | 'composeShard': pb.ResCommon, 379 | 'fetchAnnouncement': pb.ResAnnouncement, 380 | 'readAnnouncement': pb.ResCommon, 381 | 'fetchMailInfo': pb.ResMailInfo, 382 | 'readMail': pb.ResCommon, 383 | 'deleteMail': pb.ResCommon, 384 | 'takeAttachmentFromMail': pb.ResCommon, 385 | 'receiveAchievementReward': pb.ResReceiveAchievementReward, 386 | 'receiveAchievementGroupReward': pb.ResReceiveAchievementGroupReward, 387 | 'fetchAchievementRate': pb.ResFetchAchievementRate, 388 | 'fetchAchievement': pb.ResAchievement, 389 | 'buyShiLian': pb.ResCommon, 390 | 'matchShiLian': pb.ResCommon, 391 | 'goNextShiLian': pb.ResCommon, 392 | 'updateClientValue': pb.ResCommon, 393 | 'fetchClientValue': pb.ResClientValue, 394 | 'clientMessage': pb.ResCommon, 395 | 'fetchCurrentMatchInfo': pb.ResCurrentMatchInfo, 396 | 'userComplain': pb.ResCommon, 397 | 'fetchReviveCoinInfo': pb.ResReviveCoinInfo, 398 | 'gainReviveCoin': pb.ResCommon, 399 | 'fetchDailyTask': pb.ResDailyTask, 400 | 'refreshDailyTask': pb.ResRefreshDailyTask, 401 | 'useGiftCode': pb.ResUseGiftCode, 402 | 'useSpecialGiftCode': pb.ResUseSpecialGiftCode, 403 | 'fetchTitleList': pb.ResTitleList, 404 | 'useTitle': pb.ResCommon, 405 | 'sendClientMessage': pb.ResCommon, 406 | 'fetchGameLiveInfo': pb.ResGameLiveInfo, 407 | 'fetchGameLiveLeftSegment': pb.ResGameLiveLeftSegment, 408 | 'fetchGameLiveList': pb.ResGameLiveList, 409 | 'fetchCommentSetting': pb.ResCommentSetting, 410 | 'updateCommentSetting': pb.ResCommon, 411 | 'fetchCommentList': pb.ResFetchCommentList, 412 | 'fetchCommentContent': pb.ResFetchCommentContent, 413 | 'leaveComment': pb.ResCommon, 414 | 'deleteComment': pb.ResCommon, 415 | 'updateReadComment': pb.ResCommon, 416 | 'fetchRollingNotice': pb.ReqRollingNotice, 417 | 'fetchServerTime': pb.ResServerTime, 418 | 'fetchPlatformProducts': pb.ResPlatformBillingProducts, 419 | 'cancelGooglePlayOrder': pb.ResCommon, 420 | 'openChest': pb.ResOpenChest, 421 | 'buyFromChestShop': pb.ResBuyFromChestShop, 422 | 'fetchDailySignInInfo': pb.ResDailySignInInfo, 423 | 'doDailySignIn': pb.ResCommon, 424 | 'doActivitySignIn': pb.ResDoActivitySignIn, 425 | 'fetchCharacterInfo': pb.ResCharacterInfo, 426 | 'updateCharacterSort': pb.ResCommon, 427 | 'changeMainCharacter': pb.ResCommon, 428 | 'changeCharacterSkin': pb.ResCommon, 429 | 'changeCharacterView': pb.ResCommon, 430 | 'setHiddenCharacter': pb.ResSetHiddenCharacter, 431 | 'sendGiftToCharacter': pb.ResSendGiftToCharacter, 432 | 'sellItem': pb.ResCommon, 433 | 'fetchCommonView': pb.ResCommonView, 434 | 'changeCommonView': pb.ResCommon, 435 | 'saveCommonViews': pb.ResCommon, 436 | 'fetchCommonViews': pb.ResCommonViews, 437 | 'fetchAllCommonViews': pb.ResAllcommonViews, 438 | 'useCommonView': pb.ResCommon, 439 | 'upgradeCharacter': pb.ResUpgradeCharacter, 440 | 'addFinishedEnding': pb.ResCommon, 441 | 'receiveEndingReward': pb.ResCommon, 442 | 'gameMasterCommand': pb.ResCommon, 443 | 'fetchShopInfo': pb.ResShopInfo, 444 | 'buyFromShop': pb.ResBuyFromShop, 445 | 'buyFromZHP': pb.ResCommon, 446 | 'refreshZHPShop': pb.ResRefreshZHPShop, 447 | 'fetchMonthTicketInfo': pb.ResMonthTicketInfo, 448 | 'payMonthTicket': pb.ResPayMonthTicket, 449 | 'exchangeCurrency': pb.ResCommon, 450 | 'exchangeChestStone': pb.ResCommon, 451 | 'exchangeDiamond': pb.ResCommon, 452 | 'fetchServerSettings': pb.ResServerSettings, 453 | 'fetchAccountSettings': pb.ResAccountSettings, 454 | 'updateAccountSettings': pb.ResCommon, 455 | 'fetchModNicknameTime': pb.ResModNicknameTime, 456 | 'createWechatNativeOrder': pb.ResCreateWechatNativeOrder, 457 | 'createWechatAppOrder': pb.ResCreateWechatAppOrder, 458 | 'createAlipayOrder': pb.ResCreateAlipayOrder, 459 | 'createAlipayScanOrder': pb.ResCreateAlipayScanOrder, 460 | 'createAlipayAppOrder': pb.ResCreateAlipayAppOrder, 461 | 'createJPCreditCardOrder': pb.ResCreateJPCreditCardOrder, 462 | 'createJPPaypalOrder': pb.ResCreateJPPaypalOrder, 463 | 'createJPAuOrder': pb.ResCreateJPAuOrder, 464 | 'createJPDocomoOrder': pb.ResCreateJPDocomoOrder, 465 | 'createJPWebMoneyOrder': pb.ResCreateJPWebMoneyOrder, 466 | 'createJPSoftbankOrder': pb.ResCreateJPSoftbankOrder, 467 | 'createJPPayPayOrder': pb.ResCreateJPPayPayOrder, 468 | 'fetchJPCommonCreditCardOrder': pb.ResFetchJPCommonCreditCardOrder, 469 | 'createJPGMOOrder': pb.ResCreateJPGMOOrder, 470 | 'createENPaypalOrder': pb.ResCreateENPaypalOrder, 471 | 'createENMasterCardOrder': pb.ResCreateENMasterCardOrder, 472 | 'createENVisaOrder': pb.ResCreateENVisaOrder, 473 | 'createENJCBOrder': pb.ResCreateENJCBOrder, 474 | 'createENAlipayOrder': pb.ResCreateENAlipayOrder, 475 | 'createKRPaypalOrder': pb.ResCreateKRPaypalOrder, 476 | 'createKRMasterCardOrder': pb.ResCreateKRMasterCardOrder, 477 | 'createKRVisaOrder': pb.ResCreateKRVisaOrder, 478 | 'createKRJCBOrder': pb.ResCreateKRJCBOrder, 479 | 'createKRAlipayOrder': pb.ResCreateKRAlipayOrder, 480 | 'createDMMOrder': pb.ResCreateDmmOrder, 481 | 'createIAPOrder': pb.ResCreateIAPOrder, 482 | 'createSteamOrder': pb.ResCreateSteamOrder, 483 | 'verifySteamOrder': pb.ResCommon, 484 | 'createMyCardAndroidOrder': pb.ResCreateMyCardOrder, 485 | 'createMyCardWebOrder': pb.ResCreateMyCardOrder, 486 | 'createPaypalOrder': pb.ResCreatePaypalOrder, 487 | 'createXsollaOrder': pb.ResCreateXsollaOrder, 488 | 'verifyMyCardOrder': pb.ResCommon, 489 | 'verificationIAPOrder': pb.ResVerificationIAPOrder, 490 | 'createYostarSDKOrder': pb.ResCreateYostarOrder, 491 | 'createBillingOrder': pb.ResCreateBillingOrder, 492 | 'solveGooglePlayOrder': pb.ResCommon, 493 | 'solveGooglePayOrderV3': pb.ResCommon, 494 | 'deliverAA32Order': pb.ResCommon, 495 | 'fetchMisc': pb.ResMisc, 496 | 'modifySignature': pb.ResCommon, 497 | 'fetchIDCardInfo': pb.ResIDCardInfo, 498 | 'updateIDCardInfo': pb.ResCommon, 499 | 'fetchVipReward': pb.ResVipReward, 500 | 'gainVipReward': pb.ResCommon, 501 | 'fetchRefundOrder': pb.ResFetchRefundOrder, 502 | 'fetchCustomizedContestList': pb.ResFetchCustomizedContestList, 503 | 'fetchCustomizedContestExtendInfo': pb.ResFetchCustomizedContestExtendInfo, 504 | 'fetchCustomizedContestAuthInfo': pb.ResFetchCustomizedContestAuthInfo, 505 | 'enterCustomizedContest': pb.ResEnterCustomizedContest, 506 | 'leaveCustomizedContest': pb.ResCommon, 507 | 'fetchCustomizedContestOnlineInfo': pb.ResFetchCustomizedContestOnlineInfo, 508 | 'fetchCustomizedContestByContestId': pb.ResFetchCustomizedContestByContestId, 509 | 'startCustomizedContest': pb.ResCommon, 510 | 'stopCustomizedContest': pb.ResCommon, 511 | 'joinCustomizedContestChatRoom': pb.ResJoinCustomizedContestChatRoom, 512 | 'leaveCustomizedContestChatRoom': pb.ResCommon, 513 | 'sayChatMessage': pb.ResCommon, 514 | 'fetchCustomizedContestGameRecords': pb.ResFetchCustomizedContestGameRecords, 515 | 'fetchCustomizedContestGameLiveList': pb.ResFetchCustomizedContestGameLiveList, 516 | 'followCustomizedContest': pb.ResCommon, 517 | 'unfollowCustomizedContest': pb.ResCommon, 518 | 'fetchActivityList': pb.ResActivityList, 519 | 'fetchAccountActivityData': pb.ResAccountActivityData, 520 | 'exchangeActivityItem': pb.ResExchangeActivityItem, 521 | 'completeActivityTask': pb.ResCommon, 522 | 'completeActivityFlipTask': pb.ResCommon, 523 | 'completePeriodActivityTask': pb.ResCommon, 524 | 'completePeriodActivityTaskBatch': pb.ResCommon, 525 | 'completeRandomActivityTask': pb.ResCommon, 526 | 'receiveActivityFlipTask': pb.ResReceiveActivityFlipTask, 527 | 'completeSegmentTaskReward': pb.ResCompleteSegmentTaskReward, 528 | 'fetchActivityFlipInfo': pb.ResFetchActivityFlipInfo, 529 | 'gainAccumulatedPointActivityReward': pb.ResCommon, 530 | 'gainMultiPointActivityReward': pb.ResCommon, 531 | 'fetchRankPointLeaderboard': pb.ResFetchRankPointLeaderboard, 532 | 'gainRankPointReward': pb.ResCommon, 533 | 'richmanActivityNextMove': pb.ResRichmanNextMove, 534 | 'richmanAcitivitySpecialMove': pb.ResRichmanNextMove, 535 | 'richmanActivityChestInfo': pb.ResRichmanChestInfo, 536 | 'createGameObserveAuth': pb.ResCreateGameObserveAuth, 537 | 'refreshGameObserveAuth': pb.ResRefreshGameObserveAuth, 538 | 'fetchActivityBuff': pb.ResActivityBuff, 539 | 'upgradeActivityBuff': pb.ResActivityBuff, 540 | 'upgradeActivityLevel': pb.ResUpgradeActivityLevel, 541 | 'receiveUpgradeActivityReward': pb.ResReceiveUpgradeActivityReward, 542 | 'upgradeChallenge': pb.ResUpgradeChallenge, 543 | 'refreshChallenge': pb.ResRefreshChallenge, 544 | 'fetchChallengeInfo': pb.ResFetchChallengeInfo, 545 | 'forceCompleteChallengeTask': pb.ResCommon, 546 | 'fetchChallengeSeason': pb.ResChallengeSeasonInfo, 547 | 'receiveChallengeRankReward': pb.ResReceiveChallengeRankReward, 548 | 'fetchABMatchInfo': pb.ResFetchABMatch, 549 | 'buyInABMatch': pb.ResCommon, 550 | 'receiveABMatchReward': pb.ResCommon, 551 | 'quitABMatch': pb.ResCommon, 552 | 'startUnifiedMatch': pb.ResCommon, 553 | 'cancelUnifiedMatch': pb.ResCommon, 554 | 'fetchGamePointRank': pb.ResGamePointRank, 555 | 'fetchSelfGamePointRank': pb.ResFetchSelfGamePointRank, 556 | 'readSNS': pb.ResReadSNS, 557 | 'replySNS': pb.ResReplySNS, 558 | 'likeSNS': pb.ResLikeSNS, 559 | 'digMine': pb.ResDigMine, 560 | 'fetchLastPrivacy': pb.ResFetchLastPrivacy, 561 | 'checkPrivacy': pb.ResCommon, 562 | 'responseCaptcha': pb.ResCommon, 563 | 'fetchRPGBattleHistory': pb.ResFetchRPGBattleHistory, 564 | 'fetchRPGBattleHistoryV2': pb.ResFetchRPGBattleHistoryV2, 565 | 'receiveRPGRewards': pb.ResReceiveRPGRewards, 566 | 'receiveRPGReward': pb.ResReceiveRPGRewards, 567 | 'buyArenaTicket': pb.ResCommon, 568 | 'enterArena': pb.ResCommon, 569 | 'receiveArenaReward': pb.ResArenaReward, 570 | 'fetchOBToken': pb.ResFetchOBToken, 571 | 'receiveCharacterRewards': pb.ResReceiveCharacterRewards, 572 | 'feedActivityFeed': pb.ResFeedActivityFeed, 573 | 'sendActivityGiftToFriend': pb.ResSendActivityGiftToFriend, 574 | 'receiveActivityGift': pb.ResCommon, 575 | 'receiveAllActivityGift': pb.ResReceiveAllActivityGift, 576 | 'fetchFriendGiftActivityData': pb.ResFetchFriendGiftActivityData, 577 | 'openPreChestItem': pb.ResOpenPreChestItem, 578 | 'fetchVoteActivity': pb.ResFetchVoteActivity, 579 | 'voteActivity': pb.ResVoteActivity, 580 | 'unlockActivitySpot': pb.ResCommon, 581 | 'unlockActivitySpotEnding': pb.ResCommon, 582 | 'receiveActivitySpotReward': pb.ResReceiveActivitySpotReward, 583 | 'deleteAccount': pb.ResDeleteAccount, 584 | 'cancelDeleteAccount': pb.ResCommon, 585 | 'logReport': pb.ResCommon, 586 | 'bindOauth2': pb.ResCommon, 587 | 'fetchOauth2Info': pb.ResFetchOauth2, 588 | 'setLoadingImage': pb.ResCommon, 589 | 'fetchShopInterval': pb.ResFetchShopInterval, 590 | 'fetchActivityInterval': pb.ResFetchActivityInterval, 591 | 'fetchRecentFriend': pb.ResFetchrecentFriend, 592 | 'openGacha': pb.ResOpenGacha, 593 | 'taskRequest': pb.ResCommon, 594 | 'simulationActivityTrain': pb.ResSimulationActivityTrain, 595 | 'fetchSimulationGameRecord': pb.ResFetchSimulationGameRecord, 596 | 'startSimulationActivityGame': pb.ResStartSimulationActivityGame, 597 | 'fetchSimulationGameRank': pb.ResFetchSimulationGameRank, 598 | } 599 | 600 | def get_package_name(self): 601 | return 'lq' 602 | 603 | def get_service_name(self): 604 | return 'Lobby' 605 | 606 | def get_req_class(self, method): 607 | return Lobby._req[method] 608 | 609 | def get_res_class(self, method): 610 | return Lobby._res[method] 611 | 612 | async def fetch_connection_info(self, req): 613 | return await self.call_method('fetchConnectionInfo', req) 614 | 615 | async def fetch_queue_info(self, req): 616 | return await self.call_method('fetchQueueInfo', req) 617 | 618 | async def cancel_queue(self, req): 619 | return await self.call_method('cancelQueue', req) 620 | 621 | async def openid_check(self, req): 622 | return await self.call_method('openidCheck', req) 623 | 624 | async def signup(self, req): 625 | return await self.call_method('signup', req) 626 | 627 | async def login(self, req): 628 | return await self.call_method('login', req) 629 | 630 | async def login_success(self, req): 631 | return await self.call_method('loginSuccess', req) 632 | 633 | async def email_login(self, req): 634 | return await self.call_method('emailLogin', req) 635 | 636 | async def oauth2_auth(self, req): 637 | return await self.call_method('oauth2Auth', req) 638 | 639 | async def oauth2_check(self, req): 640 | return await self.call_method('oauth2Check', req) 641 | 642 | async def oauth2_signup(self, req): 643 | return await self.call_method('oauth2Signup', req) 644 | 645 | async def oauth2_login(self, req): 646 | return await self.call_method('oauth2Login', req) 647 | 648 | async def dmm_pre_login(self, req): 649 | return await self.call_method('dmmPreLogin', req) 650 | 651 | async def create_phone_verify_code(self, req): 652 | return await self.call_method('createPhoneVerifyCode', req) 653 | 654 | async def create_email_verify_code(self, req): 655 | return await self.call_method('createEmailVerifyCode', req) 656 | 657 | async def verfify_code_for_secure(self, req): 658 | return await self.call_method('verfifyCodeForSecure', req) 659 | 660 | async def bind_phone_number(self, req): 661 | return await self.call_method('bindPhoneNumber', req) 662 | 663 | async def unbind_phone_number(self, req): 664 | return await self.call_method('unbindPhoneNumber', req) 665 | 666 | async def fetch_phone_login_bind(self, req): 667 | return await self.call_method('fetchPhoneLoginBind', req) 668 | 669 | async def create_phone_login_bind(self, req): 670 | return await self.call_method('createPhoneLoginBind', req) 671 | 672 | async def bind_email(self, req): 673 | return await self.call_method('bindEmail', req) 674 | 675 | async def modify_password(self, req): 676 | return await self.call_method('modifyPassword', req) 677 | 678 | async def bind_account(self, req): 679 | return await self.call_method('bindAccount', req) 680 | 681 | async def logout(self, req): 682 | return await self.call_method('logout', req) 683 | 684 | async def heatbeat(self, req): 685 | return await self.call_method('heatbeat', req) 686 | 687 | async def login_beat(self, req): 688 | return await self.call_method('loginBeat', req) 689 | 690 | async def create_nickname(self, req): 691 | return await self.call_method('createNickname', req) 692 | 693 | async def modify_nickname(self, req): 694 | return await self.call_method('modifyNickname', req) 695 | 696 | async def modify_birthday(self, req): 697 | return await self.call_method('modifyBirthday', req) 698 | 699 | async def fetch_room(self, req): 700 | return await self.call_method('fetchRoom', req) 701 | 702 | async def create_room(self, req): 703 | return await self.call_method('createRoom', req) 704 | 705 | async def join_room(self, req): 706 | return await self.call_method('joinRoom', req) 707 | 708 | async def leave_room(self, req): 709 | return await self.call_method('leaveRoom', req) 710 | 711 | async def ready_play(self, req): 712 | return await self.call_method('readyPlay', req) 713 | 714 | async def dressing_status(self, req): 715 | return await self.call_method('dressingStatus', req) 716 | 717 | async def start_room(self, req): 718 | return await self.call_method('startRoom', req) 719 | 720 | async def kick_player(self, req): 721 | return await self.call_method('kickPlayer', req) 722 | 723 | async def modify_room(self, req): 724 | return await self.call_method('modifyRoom', req) 725 | 726 | async def match_game(self, req): 727 | return await self.call_method('matchGame', req) 728 | 729 | async def cancel_match(self, req): 730 | return await self.call_method('cancelMatch', req) 731 | 732 | async def fetch_account_info(self, req): 733 | return await self.call_method('fetchAccountInfo', req) 734 | 735 | async def change_avatar(self, req): 736 | return await self.call_method('changeAvatar', req) 737 | 738 | async def receive_version_reward(self, req): 739 | return await self.call_method('receiveVersionReward', req) 740 | 741 | async def fetch_account_statistic_info(self, req): 742 | return await self.call_method('fetchAccountStatisticInfo', req) 743 | 744 | async def fetch_account_challenge_rank_info(self, req): 745 | return await self.call_method('fetchAccountChallengeRankInfo', req) 746 | 747 | async def fetch_account_character_info(self, req): 748 | return await self.call_method('fetchAccountCharacterInfo', req) 749 | 750 | async def shop_purchase(self, req): 751 | return await self.call_method('shopPurchase', req) 752 | 753 | async def fetch_game_record(self, req): 754 | return await self.call_method('fetchGameRecord', req) 755 | 756 | async def read_game_record(self, req): 757 | return await self.call_method('readGameRecord', req) 758 | 759 | async def fetch_game_record_list(self, req): 760 | return await self.call_method('fetchGameRecordList', req) 761 | 762 | async def fetch_collected_game_record_list(self, req): 763 | return await self.call_method('fetchCollectedGameRecordList', req) 764 | 765 | async def fetch_game_records_detail(self, req): 766 | return await self.call_method('fetchGameRecordsDetail', req) 767 | 768 | async def add_collected_game_record(self, req): 769 | return await self.call_method('addCollectedGameRecord', req) 770 | 771 | async def remove_collected_game_record(self, req): 772 | return await self.call_method('removeCollectedGameRecord', req) 773 | 774 | async def change_collected_game_record_remarks(self, req): 775 | return await self.call_method('changeCollectedGameRecordRemarks', req) 776 | 777 | async def fetch_level_leaderboard(self, req): 778 | return await self.call_method('fetchLevelLeaderboard', req) 779 | 780 | async def fetch_challenge_leaderboard(self, req): 781 | return await self.call_method('fetchChallengeLeaderboard', req) 782 | 783 | async def fetch_muti_challenge_level(self, req): 784 | return await self.call_method('fetchMutiChallengeLevel', req) 785 | 786 | async def fetch_multi_account_brief(self, req): 787 | return await self.call_method('fetchMultiAccountBrief', req) 788 | 789 | async def fetch_friend_list(self, req): 790 | return await self.call_method('fetchFriendList', req) 791 | 792 | async def fetch_friend_apply_list(self, req): 793 | return await self.call_method('fetchFriendApplyList', req) 794 | 795 | async def apply_friend(self, req): 796 | return await self.call_method('applyFriend', req) 797 | 798 | async def handle_friend_apply(self, req): 799 | return await self.call_method('handleFriendApply', req) 800 | 801 | async def remove_friend(self, req): 802 | return await self.call_method('removeFriend', req) 803 | 804 | async def search_account_by_id(self, req): 805 | return await self.call_method('searchAccountById', req) 806 | 807 | async def search_account_by_pattern(self, req): 808 | return await self.call_method('searchAccountByPattern', req) 809 | 810 | async def fetch_account_state(self, req): 811 | return await self.call_method('fetchAccountState', req) 812 | 813 | async def fetch_bag_info(self, req): 814 | return await self.call_method('fetchBagInfo', req) 815 | 816 | async def use_bag_item(self, req): 817 | return await self.call_method('useBagItem', req) 818 | 819 | async def open_manual_item(self, req): 820 | return await self.call_method('openManualItem', req) 821 | 822 | async def open_random_reward_item(self, req): 823 | return await self.call_method('openRandomRewardItem', req) 824 | 825 | async def open_all_reward_item(self, req): 826 | return await self.call_method('openAllRewardItem', req) 827 | 828 | async def compose_shard(self, req): 829 | return await self.call_method('composeShard', req) 830 | 831 | async def fetch_announcement(self, req): 832 | return await self.call_method('fetchAnnouncement', req) 833 | 834 | async def read_announcement(self, req): 835 | return await self.call_method('readAnnouncement', req) 836 | 837 | async def fetch_mail_info(self, req): 838 | return await self.call_method('fetchMailInfo', req) 839 | 840 | async def read_mail(self, req): 841 | return await self.call_method('readMail', req) 842 | 843 | async def delete_mail(self, req): 844 | return await self.call_method('deleteMail', req) 845 | 846 | async def take_attachment_from_mail(self, req): 847 | return await self.call_method('takeAttachmentFromMail', req) 848 | 849 | async def receive_achievement_reward(self, req): 850 | return await self.call_method('receiveAchievementReward', req) 851 | 852 | async def receive_achievement_group_reward(self, req): 853 | return await self.call_method('receiveAchievementGroupReward', req) 854 | 855 | async def fetch_achievement_rate(self, req): 856 | return await self.call_method('fetchAchievementRate', req) 857 | 858 | async def fetch_achievement(self, req): 859 | return await self.call_method('fetchAchievement', req) 860 | 861 | async def buy_shi_lian(self, req): 862 | return await self.call_method('buyShiLian', req) 863 | 864 | async def match_shi_lian(self, req): 865 | return await self.call_method('matchShiLian', req) 866 | 867 | async def go_next_shi_lian(self, req): 868 | return await self.call_method('goNextShiLian', req) 869 | 870 | async def update_client_value(self, req): 871 | return await self.call_method('updateClientValue', req) 872 | 873 | async def fetch_client_value(self, req): 874 | return await self.call_method('fetchClientValue', req) 875 | 876 | async def client_message(self, req): 877 | return await self.call_method('clientMessage', req) 878 | 879 | async def fetch_current_match_info(self, req): 880 | return await self.call_method('fetchCurrentMatchInfo', req) 881 | 882 | async def user_complain(self, req): 883 | return await self.call_method('userComplain', req) 884 | 885 | async def fetch_revive_coin_info(self, req): 886 | return await self.call_method('fetchReviveCoinInfo', req) 887 | 888 | async def gain_revive_coin(self, req): 889 | return await self.call_method('gainReviveCoin', req) 890 | 891 | async def fetch_daily_task(self, req): 892 | return await self.call_method('fetchDailyTask', req) 893 | 894 | async def refresh_daily_task(self, req): 895 | return await self.call_method('refreshDailyTask', req) 896 | 897 | async def use_gift_code(self, req): 898 | return await self.call_method('useGiftCode', req) 899 | 900 | async def use_special_gift_code(self, req): 901 | return await self.call_method('useSpecialGiftCode', req) 902 | 903 | async def fetch_title_list(self, req): 904 | return await self.call_method('fetchTitleList', req) 905 | 906 | async def use_title(self, req): 907 | return await self.call_method('useTitle', req) 908 | 909 | async def send_client_message(self, req): 910 | return await self.call_method('sendClientMessage', req) 911 | 912 | async def fetch_game_live_info(self, req): 913 | return await self.call_method('fetchGameLiveInfo', req) 914 | 915 | async def fetch_game_live_left_segment(self, req): 916 | return await self.call_method('fetchGameLiveLeftSegment', req) 917 | 918 | async def fetch_game_live_list(self, req): 919 | return await self.call_method('fetchGameLiveList', req) 920 | 921 | async def fetch_comment_setting(self, req): 922 | return await self.call_method('fetchCommentSetting', req) 923 | 924 | async def update_comment_setting(self, req): 925 | return await self.call_method('updateCommentSetting', req) 926 | 927 | async def fetch_comment_list(self, req): 928 | return await self.call_method('fetchCommentList', req) 929 | 930 | async def fetch_comment_content(self, req): 931 | return await self.call_method('fetchCommentContent', req) 932 | 933 | async def leave_comment(self, req): 934 | return await self.call_method('leaveComment', req) 935 | 936 | async def delete_comment(self, req): 937 | return await self.call_method('deleteComment', req) 938 | 939 | async def update_read_comment(self, req): 940 | return await self.call_method('updateReadComment', req) 941 | 942 | async def fetch_rolling_notice(self, req): 943 | return await self.call_method('fetchRollingNotice', req) 944 | 945 | async def fetch_server_time(self, req): 946 | return await self.call_method('fetchServerTime', req) 947 | 948 | async def fetch_platform_products(self, req): 949 | return await self.call_method('fetchPlatformProducts', req) 950 | 951 | async def cancel_google_play_order(self, req): 952 | return await self.call_method('cancelGooglePlayOrder', req) 953 | 954 | async def open_chest(self, req): 955 | return await self.call_method('openChest', req) 956 | 957 | async def buy_from_chest_shop(self, req): 958 | return await self.call_method('buyFromChestShop', req) 959 | 960 | async def fetch_daily_sign_in_info(self, req): 961 | return await self.call_method('fetchDailySignInInfo', req) 962 | 963 | async def do_daily_sign_in(self, req): 964 | return await self.call_method('doDailySignIn', req) 965 | 966 | async def do_activity_sign_in(self, req): 967 | return await self.call_method('doActivitySignIn', req) 968 | 969 | async def fetch_character_info(self, req): 970 | return await self.call_method('fetchCharacterInfo', req) 971 | 972 | async def update_character_sort(self, req): 973 | return await self.call_method('updateCharacterSort', req) 974 | 975 | async def change_main_character(self, req): 976 | return await self.call_method('changeMainCharacter', req) 977 | 978 | async def change_character_skin(self, req): 979 | return await self.call_method('changeCharacterSkin', req) 980 | 981 | async def change_character_view(self, req): 982 | return await self.call_method('changeCharacterView', req) 983 | 984 | async def set_hidden_character(self, req): 985 | return await self.call_method('setHiddenCharacter', req) 986 | 987 | async def send_gift_to_character(self, req): 988 | return await self.call_method('sendGiftToCharacter', req) 989 | 990 | async def sell_item(self, req): 991 | return await self.call_method('sellItem', req) 992 | 993 | async def fetch_common_view(self, req): 994 | return await self.call_method('fetchCommonView', req) 995 | 996 | async def change_common_view(self, req): 997 | return await self.call_method('changeCommonView', req) 998 | 999 | async def save_common_views(self, req): 1000 | return await self.call_method('saveCommonViews', req) 1001 | 1002 | async def fetch_common_views(self, req): 1003 | return await self.call_method('fetchCommonViews', req) 1004 | 1005 | async def fetch_all_common_views(self, req): 1006 | return await self.call_method('fetchAllCommonViews', req) 1007 | 1008 | async def use_common_view(self, req): 1009 | return await self.call_method('useCommonView', req) 1010 | 1011 | async def upgrade_character(self, req): 1012 | return await self.call_method('upgradeCharacter', req) 1013 | 1014 | async def add_finished_ending(self, req): 1015 | return await self.call_method('addFinishedEnding', req) 1016 | 1017 | async def receive_ending_reward(self, req): 1018 | return await self.call_method('receiveEndingReward', req) 1019 | 1020 | async def game_master_command(self, req): 1021 | return await self.call_method('gameMasterCommand', req) 1022 | 1023 | async def fetch_shop_info(self, req): 1024 | return await self.call_method('fetchShopInfo', req) 1025 | 1026 | async def buy_from_shop(self, req): 1027 | return await self.call_method('buyFromShop', req) 1028 | 1029 | async def buy_from_zhp(self, req): 1030 | return await self.call_method('buyFromZHP', req) 1031 | 1032 | async def refresh_zhp_shop(self, req): 1033 | return await self.call_method('refreshZHPShop', req) 1034 | 1035 | async def fetch_month_ticket_info(self, req): 1036 | return await self.call_method('fetchMonthTicketInfo', req) 1037 | 1038 | async def pay_month_ticket(self, req): 1039 | return await self.call_method('payMonthTicket', req) 1040 | 1041 | async def exchange_currency(self, req): 1042 | return await self.call_method('exchangeCurrency', req) 1043 | 1044 | async def exchange_chest_stone(self, req): 1045 | return await self.call_method('exchangeChestStone', req) 1046 | 1047 | async def exchange_diamond(self, req): 1048 | return await self.call_method('exchangeDiamond', req) 1049 | 1050 | async def fetch_server_settings(self, req): 1051 | return await self.call_method('fetchServerSettings', req) 1052 | 1053 | async def fetch_account_settings(self, req): 1054 | return await self.call_method('fetchAccountSettings', req) 1055 | 1056 | async def update_account_settings(self, req): 1057 | return await self.call_method('updateAccountSettings', req) 1058 | 1059 | async def fetch_mod_nickname_time(self, req): 1060 | return await self.call_method('fetchModNicknameTime', req) 1061 | 1062 | async def create_wechat_native_order(self, req): 1063 | return await self.call_method('createWechatNativeOrder', req) 1064 | 1065 | async def create_wechat_app_order(self, req): 1066 | return await self.call_method('createWechatAppOrder', req) 1067 | 1068 | async def create_alipay_order(self, req): 1069 | return await self.call_method('createAlipayOrder', req) 1070 | 1071 | async def create_alipay_scan_order(self, req): 1072 | return await self.call_method('createAlipayScanOrder', req) 1073 | 1074 | async def create_alipay_app_order(self, req): 1075 | return await self.call_method('createAlipayAppOrder', req) 1076 | 1077 | async def create_jp_credit_card_order(self, req): 1078 | return await self.call_method('createJPCreditCardOrder', req) 1079 | 1080 | async def create_jp_paypal_order(self, req): 1081 | return await self.call_method('createJPPaypalOrder', req) 1082 | 1083 | async def create_jp_au_order(self, req): 1084 | return await self.call_method('createJPAuOrder', req) 1085 | 1086 | async def create_jp_docomo_order(self, req): 1087 | return await self.call_method('createJPDocomoOrder', req) 1088 | 1089 | async def create_jp_web_money_order(self, req): 1090 | return await self.call_method('createJPWebMoneyOrder', req) 1091 | 1092 | async def create_jp_softbank_order(self, req): 1093 | return await self.call_method('createJPSoftbankOrder', req) 1094 | 1095 | async def create_jp_pay_pay_order(self, req): 1096 | return await self.call_method('createJPPayPayOrder', req) 1097 | 1098 | async def fetch_jp_common_credit_card_order(self, req): 1099 | return await self.call_method('fetchJPCommonCreditCardOrder', req) 1100 | 1101 | async def create_jpgmo_order(self, req): 1102 | return await self.call_method('createJPGMOOrder', req) 1103 | 1104 | async def create_en_paypal_order(self, req): 1105 | return await self.call_method('createENPaypalOrder', req) 1106 | 1107 | async def create_en_master_card_order(self, req): 1108 | return await self.call_method('createENMasterCardOrder', req) 1109 | 1110 | async def create_en_visa_order(self, req): 1111 | return await self.call_method('createENVisaOrder', req) 1112 | 1113 | async def create_enjcb_order(self, req): 1114 | return await self.call_method('createENJCBOrder', req) 1115 | 1116 | async def create_en_alipay_order(self, req): 1117 | return await self.call_method('createENAlipayOrder', req) 1118 | 1119 | async def create_kr_paypal_order(self, req): 1120 | return await self.call_method('createKRPaypalOrder', req) 1121 | 1122 | async def create_kr_master_card_order(self, req): 1123 | return await self.call_method('createKRMasterCardOrder', req) 1124 | 1125 | async def create_kr_visa_order(self, req): 1126 | return await self.call_method('createKRVisaOrder', req) 1127 | 1128 | async def create_krjcb_order(self, req): 1129 | return await self.call_method('createKRJCBOrder', req) 1130 | 1131 | async def create_kr_alipay_order(self, req): 1132 | return await self.call_method('createKRAlipayOrder', req) 1133 | 1134 | async def create_dmm_order(self, req): 1135 | return await self.call_method('createDMMOrder', req) 1136 | 1137 | async def create_iap_order(self, req): 1138 | return await self.call_method('createIAPOrder', req) 1139 | 1140 | async def create_steam_order(self, req): 1141 | return await self.call_method('createSteamOrder', req) 1142 | 1143 | async def verify_steam_order(self, req): 1144 | return await self.call_method('verifySteamOrder', req) 1145 | 1146 | async def create_my_card_android_order(self, req): 1147 | return await self.call_method('createMyCardAndroidOrder', req) 1148 | 1149 | async def create_my_card_web_order(self, req): 1150 | return await self.call_method('createMyCardWebOrder', req) 1151 | 1152 | async def create_paypal_order(self, req): 1153 | return await self.call_method('createPaypalOrder', req) 1154 | 1155 | async def create_xsolla_order(self, req): 1156 | return await self.call_method('createXsollaOrder', req) 1157 | 1158 | async def verify_my_card_order(self, req): 1159 | return await self.call_method('verifyMyCardOrder', req) 1160 | 1161 | async def verification_iap_order(self, req): 1162 | return await self.call_method('verificationIAPOrder', req) 1163 | 1164 | async def create_yostar_sdk_order(self, req): 1165 | return await self.call_method('createYostarSDKOrder', req) 1166 | 1167 | async def create_billing_order(self, req): 1168 | return await self.call_method('createBillingOrder', req) 1169 | 1170 | async def solve_google_play_order(self, req): 1171 | return await self.call_method('solveGooglePlayOrder', req) 1172 | 1173 | async def solve_google_pay_order_v3(self, req): 1174 | return await self.call_method('solveGooglePayOrderV3', req) 1175 | 1176 | async def deliver_aa32_order(self, req): 1177 | return await self.call_method('deliverAA32Order', req) 1178 | 1179 | async def fetch_misc(self, req): 1180 | return await self.call_method('fetchMisc', req) 1181 | 1182 | async def modify_signature(self, req): 1183 | return await self.call_method('modifySignature', req) 1184 | 1185 | async def fetch_id_card_info(self, req): 1186 | return await self.call_method('fetchIDCardInfo', req) 1187 | 1188 | async def update_id_card_info(self, req): 1189 | return await self.call_method('updateIDCardInfo', req) 1190 | 1191 | async def fetch_vip_reward(self, req): 1192 | return await self.call_method('fetchVipReward', req) 1193 | 1194 | async def gain_vip_reward(self, req): 1195 | return await self.call_method('gainVipReward', req) 1196 | 1197 | async def fetch_refund_order(self, req): 1198 | return await self.call_method('fetchRefundOrder', req) 1199 | 1200 | async def fetch_customized_contest_list(self, req): 1201 | return await self.call_method('fetchCustomizedContestList', req) 1202 | 1203 | async def fetch_customized_contest_extend_info(self, req): 1204 | return await self.call_method('fetchCustomizedContestExtendInfo', req) 1205 | 1206 | async def fetch_customized_contest_auth_info(self, req): 1207 | return await self.call_method('fetchCustomizedContestAuthInfo', req) 1208 | 1209 | async def enter_customized_contest(self, req): 1210 | return await self.call_method('enterCustomizedContest', req) 1211 | 1212 | async def leave_customized_contest(self, req): 1213 | return await self.call_method('leaveCustomizedContest', req) 1214 | 1215 | async def fetch_customized_contest_online_info(self, req): 1216 | return await self.call_method('fetchCustomizedContestOnlineInfo', req) 1217 | 1218 | async def fetch_customized_contest_by_contest_id(self, req): 1219 | return await self.call_method('fetchCustomizedContestByContestId', req) 1220 | 1221 | async def start_customized_contest(self, req): 1222 | return await self.call_method('startCustomizedContest', req) 1223 | 1224 | async def stop_customized_contest(self, req): 1225 | return await self.call_method('stopCustomizedContest', req) 1226 | 1227 | async def join_customized_contest_chat_room(self, req): 1228 | return await self.call_method('joinCustomizedContestChatRoom', req) 1229 | 1230 | async def leave_customized_contest_chat_room(self, req): 1231 | return await self.call_method('leaveCustomizedContestChatRoom', req) 1232 | 1233 | async def say_chat_message(self, req): 1234 | return await self.call_method('sayChatMessage', req) 1235 | 1236 | async def fetch_customized_contest_game_records(self, req): 1237 | return await self.call_method('fetchCustomizedContestGameRecords', req) 1238 | 1239 | async def fetch_customized_contest_game_live_list(self, req): 1240 | return await self.call_method('fetchCustomizedContestGameLiveList', req) 1241 | 1242 | async def follow_customized_contest(self, req): 1243 | return await self.call_method('followCustomizedContest', req) 1244 | 1245 | async def unfollow_customized_contest(self, req): 1246 | return await self.call_method('unfollowCustomizedContest', req) 1247 | 1248 | async def fetch_activity_list(self, req): 1249 | return await self.call_method('fetchActivityList', req) 1250 | 1251 | async def fetch_account_activity_data(self, req): 1252 | return await self.call_method('fetchAccountActivityData', req) 1253 | 1254 | async def exchange_activity_item(self, req): 1255 | return await self.call_method('exchangeActivityItem', req) 1256 | 1257 | async def complete_activity_task(self, req): 1258 | return await self.call_method('completeActivityTask', req) 1259 | 1260 | async def complete_activity_flip_task(self, req): 1261 | return await self.call_method('completeActivityFlipTask', req) 1262 | 1263 | async def complete_period_activity_task(self, req): 1264 | return await self.call_method('completePeriodActivityTask', req) 1265 | 1266 | async def complete_period_activity_task_batch(self, req): 1267 | return await self.call_method('completePeriodActivityTaskBatch', req) 1268 | 1269 | async def complete_random_activity_task(self, req): 1270 | return await self.call_method('completeRandomActivityTask', req) 1271 | 1272 | async def receive_activity_flip_task(self, req): 1273 | return await self.call_method('receiveActivityFlipTask', req) 1274 | 1275 | async def complete_segment_task_reward(self, req): 1276 | return await self.call_method('completeSegmentTaskReward', req) 1277 | 1278 | async def fetch_activity_flip_info(self, req): 1279 | return await self.call_method('fetchActivityFlipInfo', req) 1280 | 1281 | async def gain_accumulated_point_activity_reward(self, req): 1282 | return await self.call_method('gainAccumulatedPointActivityReward', req) 1283 | 1284 | async def gain_multi_point_activity_reward(self, req): 1285 | return await self.call_method('gainMultiPointActivityReward', req) 1286 | 1287 | async def fetch_rank_point_leaderboard(self, req): 1288 | return await self.call_method('fetchRankPointLeaderboard', req) 1289 | 1290 | async def gain_rank_point_reward(self, req): 1291 | return await self.call_method('gainRankPointReward', req) 1292 | 1293 | async def richman_activity_next_move(self, req): 1294 | return await self.call_method('richmanActivityNextMove', req) 1295 | 1296 | async def richman_acitivity_special_move(self, req): 1297 | return await self.call_method('richmanAcitivitySpecialMove', req) 1298 | 1299 | async def richman_activity_chest_info(self, req): 1300 | return await self.call_method('richmanActivityChestInfo', req) 1301 | 1302 | async def create_game_observe_auth(self, req): 1303 | return await self.call_method('createGameObserveAuth', req) 1304 | 1305 | async def refresh_game_observe_auth(self, req): 1306 | return await self.call_method('refreshGameObserveAuth', req) 1307 | 1308 | async def fetch_activity_buff(self, req): 1309 | return await self.call_method('fetchActivityBuff', req) 1310 | 1311 | async def upgrade_activity_buff(self, req): 1312 | return await self.call_method('upgradeActivityBuff', req) 1313 | 1314 | async def upgrade_activity_level(self, req): 1315 | return await self.call_method('upgradeActivityLevel', req) 1316 | 1317 | async def receive_upgrade_activity_reward(self, req): 1318 | return await self.call_method('receiveUpgradeActivityReward', req) 1319 | 1320 | async def upgrade_challenge(self, req): 1321 | return await self.call_method('upgradeChallenge', req) 1322 | 1323 | async def refresh_challenge(self, req): 1324 | return await self.call_method('refreshChallenge', req) 1325 | 1326 | async def fetch_challenge_info(self, req): 1327 | return await self.call_method('fetchChallengeInfo', req) 1328 | 1329 | async def force_complete_challenge_task(self, req): 1330 | return await self.call_method('forceCompleteChallengeTask', req) 1331 | 1332 | async def fetch_challenge_season(self, req): 1333 | return await self.call_method('fetchChallengeSeason', req) 1334 | 1335 | async def receive_challenge_rank_reward(self, req): 1336 | return await self.call_method('receiveChallengeRankReward', req) 1337 | 1338 | async def fetch_ab_match_info(self, req): 1339 | return await self.call_method('fetchABMatchInfo', req) 1340 | 1341 | async def buy_in_ab_match(self, req): 1342 | return await self.call_method('buyInABMatch', req) 1343 | 1344 | async def receive_ab_match_reward(self, req): 1345 | return await self.call_method('receiveABMatchReward', req) 1346 | 1347 | async def quit_ab_match(self, req): 1348 | return await self.call_method('quitABMatch', req) 1349 | 1350 | async def start_unified_match(self, req): 1351 | return await self.call_method('startUnifiedMatch', req) 1352 | 1353 | async def cancel_unified_match(self, req): 1354 | return await self.call_method('cancelUnifiedMatch', req) 1355 | 1356 | async def fetch_game_point_rank(self, req): 1357 | return await self.call_method('fetchGamePointRank', req) 1358 | 1359 | async def fetch_self_game_point_rank(self, req): 1360 | return await self.call_method('fetchSelfGamePointRank', req) 1361 | 1362 | async def read_sns(self, req): 1363 | return await self.call_method('readSNS', req) 1364 | 1365 | async def reply_sns(self, req): 1366 | return await self.call_method('replySNS', req) 1367 | 1368 | async def like_sns(self, req): 1369 | return await self.call_method('likeSNS', req) 1370 | 1371 | async def dig_mine(self, req): 1372 | return await self.call_method('digMine', req) 1373 | 1374 | async def fetch_last_privacy(self, req): 1375 | return await self.call_method('fetchLastPrivacy', req) 1376 | 1377 | async def check_privacy(self, req): 1378 | return await self.call_method('checkPrivacy', req) 1379 | 1380 | async def response_captcha(self, req): 1381 | return await self.call_method('responseCaptcha', req) 1382 | 1383 | async def fetch_rpg_battle_history(self, req): 1384 | return await self.call_method('fetchRPGBattleHistory', req) 1385 | 1386 | async def fetch_rpg_battle_history_v2(self, req): 1387 | return await self.call_method('fetchRPGBattleHistoryV2', req) 1388 | 1389 | async def receive_rpg_rewards(self, req): 1390 | return await self.call_method('receiveRPGRewards', req) 1391 | 1392 | async def receive_rpg_reward(self, req): 1393 | return await self.call_method('receiveRPGReward', req) 1394 | 1395 | async def buy_arena_ticket(self, req): 1396 | return await self.call_method('buyArenaTicket', req) 1397 | 1398 | async def enter_arena(self, req): 1399 | return await self.call_method('enterArena', req) 1400 | 1401 | async def receive_arena_reward(self, req): 1402 | return await self.call_method('receiveArenaReward', req) 1403 | 1404 | async def fetch_ob_token(self, req): 1405 | return await self.call_method('fetchOBToken', req) 1406 | 1407 | async def receive_character_rewards(self, req): 1408 | return await self.call_method('receiveCharacterRewards', req) 1409 | 1410 | async def feed_activity_feed(self, req): 1411 | return await self.call_method('feedActivityFeed', req) 1412 | 1413 | async def send_activity_gift_to_friend(self, req): 1414 | return await self.call_method('sendActivityGiftToFriend', req) 1415 | 1416 | async def receive_activity_gift(self, req): 1417 | return await self.call_method('receiveActivityGift', req) 1418 | 1419 | async def receive_all_activity_gift(self, req): 1420 | return await self.call_method('receiveAllActivityGift', req) 1421 | 1422 | async def fetch_friend_gift_activity_data(self, req): 1423 | return await self.call_method('fetchFriendGiftActivityData', req) 1424 | 1425 | async def open_pre_chest_item(self, req): 1426 | return await self.call_method('openPreChestItem', req) 1427 | 1428 | async def fetch_vote_activity(self, req): 1429 | return await self.call_method('fetchVoteActivity', req) 1430 | 1431 | async def vote_activity(self, req): 1432 | return await self.call_method('voteActivity', req) 1433 | 1434 | async def unlock_activity_spot(self, req): 1435 | return await self.call_method('unlockActivitySpot', req) 1436 | 1437 | async def unlock_activity_spot_ending(self, req): 1438 | return await self.call_method('unlockActivitySpotEnding', req) 1439 | 1440 | async def receive_activity_spot_reward(self, req): 1441 | return await self.call_method('receiveActivitySpotReward', req) 1442 | 1443 | async def delete_account(self, req): 1444 | return await self.call_method('deleteAccount', req) 1445 | 1446 | async def cancel_delete_account(self, req): 1447 | return await self.call_method('cancelDeleteAccount', req) 1448 | 1449 | async def log_report(self, req): 1450 | return await self.call_method('logReport', req) 1451 | 1452 | async def bind_oauth2(self, req): 1453 | return await self.call_method('bindOauth2', req) 1454 | 1455 | async def fetch_oauth2_info(self, req): 1456 | return await self.call_method('fetchOauth2Info', req) 1457 | 1458 | async def set_loading_image(self, req): 1459 | return await self.call_method('setLoadingImage', req) 1460 | 1461 | async def fetch_shop_interval(self, req): 1462 | return await self.call_method('fetchShopInterval', req) 1463 | 1464 | async def fetch_activity_interval(self, req): 1465 | return await self.call_method('fetchActivityInterval', req) 1466 | 1467 | async def fetch_recent_friend(self, req): 1468 | return await self.call_method('fetchRecentFriend', req) 1469 | 1470 | async def open_gacha(self, req): 1471 | return await self.call_method('openGacha', req) 1472 | 1473 | async def task_request(self, req): 1474 | return await self.call_method('taskRequest', req) 1475 | 1476 | async def simulation_activity_train(self, req): 1477 | return await self.call_method('simulationActivityTrain', req) 1478 | 1479 | async def fetch_simulation_game_record(self, req): 1480 | return await self.call_method('fetchSimulationGameRecord', req) 1481 | 1482 | async def start_simulation_activity_game(self, req): 1483 | return await self.call_method('startSimulationActivityGame', req) 1484 | 1485 | async def fetch_simulation_game_rank(self, req): 1486 | return await self.call_method('fetchSimulationGameRank', req) 1487 | 1488 | 1489 | class FastTest(MSRPCService): 1490 | version = None 1491 | 1492 | _req = { 1493 | 'authGame': pb.ReqAuthGame, 1494 | 'enterGame': pb.ReqCommon, 1495 | 'syncGame': pb.ReqSyncGame, 1496 | 'finishSyncGame': pb.ReqCommon, 1497 | 'terminateGame': pb.ReqCommon, 1498 | 'inputOperation': pb.ReqSelfOperation, 1499 | 'inputChiPengGang': pb.ReqChiPengGang, 1500 | 'confirmNewRound': pb.ReqCommon, 1501 | 'broadcastInGame': pb.ReqBroadcastInGame, 1502 | 'inputGameGMCommand': pb.ReqGMCommandInGaming, 1503 | 'fetchGamePlayerState': pb.ReqCommon, 1504 | 'checkNetworkDelay': pb.ReqCommon, 1505 | 'clearLeaving': pb.ReqCommon, 1506 | 'voteGameEnd': pb.ReqVoteGameEnd, 1507 | 'authObserve': pb.ReqAuthObserve, 1508 | 'startObserve': pb.ReqCommon, 1509 | 'stopObserve': pb.ReqCommon, 1510 | } 1511 | _res = { 1512 | 'authGame': pb.ResAuthGame, 1513 | 'enterGame': pb.ResEnterGame, 1514 | 'syncGame': pb.ResSyncGame, 1515 | 'finishSyncGame': pb.ResCommon, 1516 | 'terminateGame': pb.ResCommon, 1517 | 'inputOperation': pb.ResCommon, 1518 | 'inputChiPengGang': pb.ResCommon, 1519 | 'confirmNewRound': pb.ResCommon, 1520 | 'broadcastInGame': pb.ResCommon, 1521 | 'inputGameGMCommand': pb.ResCommon, 1522 | 'fetchGamePlayerState': pb.ResGamePlayerState, 1523 | 'checkNetworkDelay': pb.ResCommon, 1524 | 'clearLeaving': pb.ResCommon, 1525 | 'voteGameEnd': pb.ResGameEndVote, 1526 | 'authObserve': pb.ResCommon, 1527 | 'startObserve': pb.ResStartObserve, 1528 | 'stopObserve': pb.ResCommon, 1529 | } 1530 | 1531 | def get_package_name(self): 1532 | return 'lq' 1533 | 1534 | def get_service_name(self): 1535 | return 'FastTest' 1536 | 1537 | def get_req_class(self, method): 1538 | return FastTest._req[method] 1539 | 1540 | def get_res_class(self, method): 1541 | return FastTest._res[method] 1542 | 1543 | async def auth_game(self, req): 1544 | return await self.call_method('authGame', req) 1545 | 1546 | async def enter_game(self, req): 1547 | return await self.call_method('enterGame', req) 1548 | 1549 | async def sync_game(self, req): 1550 | return await self.call_method('syncGame', req) 1551 | 1552 | async def finish_sync_game(self, req): 1553 | return await self.call_method('finishSyncGame', req) 1554 | 1555 | async def terminate_game(self, req): 1556 | return await self.call_method('terminateGame', req) 1557 | 1558 | async def input_operation(self, req): 1559 | return await self.call_method('inputOperation', req) 1560 | 1561 | async def input_chi_peng_gang(self, req): 1562 | return await self.call_method('inputChiPengGang', req) 1563 | 1564 | async def confirm_new_round(self, req): 1565 | return await self.call_method('confirmNewRound', req) 1566 | 1567 | async def broadcast_in_game(self, req): 1568 | return await self.call_method('broadcastInGame', req) 1569 | 1570 | async def input_game_gm_command(self, req): 1571 | return await self.call_method('inputGameGMCommand', req) 1572 | 1573 | async def fetch_game_player_state(self, req): 1574 | return await self.call_method('fetchGamePlayerState', req) 1575 | 1576 | async def check_network_delay(self, req): 1577 | return await self.call_method('checkNetworkDelay', req) 1578 | 1579 | async def clear_leaving(self, req): 1580 | return await self.call_method('clearLeaving', req) 1581 | 1582 | async def vote_game_end(self, req): 1583 | return await self.call_method('voteGameEnd', req) 1584 | 1585 | async def auth_observe(self, req): 1586 | return await self.call_method('authObserve', req) 1587 | 1588 | async def start_observe(self, req): 1589 | return await self.call_method('startObserve', req) 1590 | 1591 | async def stop_observe(self, req): 1592 | return await self.call_method('stopObserve', req) 1593 | -------------------------------------------------------------------------------- /ms_tournament/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MahjongRepository/mahjong_soul_api/314c6c935d60bb788084fc60c30df42661543434/ms_tournament/__init__.py -------------------------------------------------------------------------------- /ms_tournament/base.py: -------------------------------------------------------------------------------- 1 | import asyncio 2 | import websockets 3 | 4 | from ms_tournament.protocol_admin_pb2 import Wrapper 5 | 6 | 7 | class MSRPCChannel: 8 | 9 | def __init__(self, endpoint): 10 | self._endpoint = endpoint 11 | self._req_events = {} 12 | self._new_req_idx = 1 13 | self._res = {} 14 | self._hooks = {} 15 | 16 | self._ws = None 17 | self._msg_dispatcher = None 18 | 19 | def add_hook(self, msg_type, hook): 20 | if msg_type not in self._hooks: 21 | self._hooks[msg_type] = [] 22 | self._hooks[msg_type].append(hook) 23 | 24 | def unwrap(self, wrapped): 25 | wrapper = Wrapper() 26 | wrapper.ParseFromString(wrapped) 27 | return wrapper 28 | 29 | def wrap(self, name, data): 30 | wrapper = Wrapper() 31 | wrapper.name = name 32 | wrapper.data = data 33 | return wrapper.SerializeToString() 34 | 35 | async def connect(self, ms_host): 36 | self._ws = await websockets.connect(self._endpoint, origin=ms_host) 37 | self._msg_dispatcher = asyncio.create_task(self.dispatch_msg()) 38 | 39 | async def close(self): 40 | self._msg_dispatcher.cancel() 41 | try: 42 | await self._msg_dispatcher 43 | except asyncio.CancelledError: 44 | pass 45 | finally: 46 | await self._ws.close() 47 | 48 | async def dispatch_msg(self): 49 | while True: 50 | msg = await self._ws.recv() 51 | type_byte = msg[0] 52 | if type_byte == 1: # NOTIFY 53 | wrapper = self.unwrap(msg[1:]) 54 | for hook in self._hooks.get(wrapper.name, []): 55 | asyncio.create_task(hook(wrapper.data)) 56 | elif type_byte == 2: # REQUEST 57 | wrapper = self.unwrap(msg[3:]) 58 | for hook in self._hooks.get(wrapper.name, []): 59 | asyncio.create_task(hook(wrapper.data)) 60 | elif type_byte == 3: # RESPONSE 61 | idx = int.from_bytes(msg[1:3], 'little') 62 | if not idx in self._req_events: 63 | continue 64 | self._res[idx] = msg 65 | self._req_events[idx].set() 66 | 67 | async def send_request(self, name, msg): 68 | idx = self._new_req_idx 69 | self._new_req_idx = (self._new_req_idx + 1) % 60007 70 | 71 | wrapped = self.wrap(name, msg) 72 | pkt = b'\x02' + idx.to_bytes(2, 'little') + wrapped 73 | 74 | evt = asyncio.Event() 75 | self._req_events[idx] = evt 76 | 77 | await self._ws.send(pkt) 78 | await evt.wait() 79 | 80 | if not idx in self._res: 81 | return None 82 | res = self._res[idx] 83 | del self._res[idx] 84 | 85 | if idx in self._req_events: 86 | del self._req_events[idx] 87 | 88 | body = self.unwrap(res[3:]) 89 | 90 | return body.data 91 | 92 | 93 | class MSRPCService: 94 | 95 | def __init__(self, channel): 96 | self._channel = channel 97 | 98 | def get_package_name(self): 99 | raise NotImplementedError 100 | 101 | def get_service_name(self): 102 | raise NotImplementedError 103 | 104 | def get_req_class(self, method): 105 | raise NotImplementedError 106 | 107 | def get_res_class(self, method): 108 | raise NotImplementedError 109 | 110 | async def call_method(self, method, req): 111 | msg = req.SerializeToString() 112 | name = '.{}.{}.{}'.format(self.get_package_name(), self.get_service_name(), method) 113 | res_msg = await self._channel.send_request(name, msg) 114 | res_class = self.get_res_class(method) 115 | res = res_class() 116 | res.ParseFromString(res_msg) 117 | return res 118 | -------------------------------------------------------------------------------- /ms_tournament/generate_proto_file.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | import json 3 | from collections import OrderedDict 4 | from io import StringIO 5 | from pprint import pprint 6 | 7 | filename = 'liqi_admin.json' 8 | data = json.load(open(filename), object_pairs_hook=OrderedDict) 9 | buf = StringIO() 10 | buf.write('syntax = "proto3";\n\n') 11 | 12 | data = data['nested'] 13 | assert len(data) == 1 14 | package_name = list(data.keys())[0] 15 | buf.write('package {};\n\n'.format(package_name)) 16 | data = data[package_name] 17 | data = data['nested'] 18 | 19 | indent = 0 20 | 21 | 22 | def write_line(line=''): 23 | buf.write('{}{}\n'.format(' ' * 2 * indent, line)) 24 | 25 | 26 | def parse_fields(fields): 27 | for name in fields: 28 | if 'rule' in fields[name]: 29 | rule = fields[name]['rule'] + ' ' 30 | else: 31 | rule = '' 32 | write_line('{}{} {} = {};'.format(rule, fields[name]['type'], name, fields[name]['id'])) 33 | 34 | 35 | def parse_methods(methods): 36 | for name in methods: 37 | write_line( 38 | 'rpc {} ({}) returns ({});'.format(name, methods[name]['requestType'], methods[name]['responseType'])) 39 | 40 | 41 | def parse_values(values): 42 | for name in values: 43 | write_line('{} = {};'.format(name, values[name])) 44 | 45 | 46 | def parse_item(name, item): 47 | global indent 48 | if 'fields' in item: 49 | write_line('message {} {{'.format(name)) 50 | indent += 1 51 | parse_fields(item['fields']) 52 | elif 'methods' in item: 53 | write_line('service {} {{'.format(name)) 54 | indent += 1 55 | parse_methods(item['methods']) 56 | elif 'values' in item: 57 | write_line('enum {} {{'.format(name)) 58 | indent += 1 59 | parse_values(item['values']) 60 | else: 61 | pprint(item) 62 | raise Exception('Unrecognized Item') 63 | if 'nested' in item: 64 | assert len(item) == 2 65 | nested = item['nested'] 66 | for child in nested: 67 | parse_item(child, nested[child]) 68 | 69 | indent -= 1 70 | write_line('}\n') 71 | 72 | 73 | for name in data: 74 | parse_item(name, data[name]) 75 | 76 | with open('protocol_admin.proto', 'w') as f: 77 | f.write(buf.getvalue()) 78 | -------------------------------------------------------------------------------- /ms_tournament/liqi_admin.json: -------------------------------------------------------------------------------- 1 | {"nested":{"lq":{"nested":{"CustomizedContestManagerApi":{"methods":{"loginContestManager":{"requestType":"ReqContestManageLogin","responseType":"ResContestManageLogin"},"oauth2AuthContestManager":{"requestType":"ReqContestManageOauth2Auth","responseType":"ResContestManageOauth2Auth"},"oauth2LoginContestManager":{"requestType":"ReqContestManageOauth2Login","responseType":"ResContestManageOauth2Login"},"logoutContestManager":{"requestType":"ReqCommon","responseType":"ResCommon"},"fetchRelatedContestList":{"requestType":"ReqCommon","responseType":"ResFetchRelatedContestList"},"createContest":{"requestType":"ReqCreateCustomizedContest","responseType":"ResCreateCustomizedContest"},"deleteContest":{"requestType":"ReqDeleteCustomizedContest","responseType":"ResCommon"},"prolongContest":{"requestType":"ReqProlongContest","responseType":"ResProlongContest"},"manageContest":{"requestType":"ReqManageContest","responseType":"ResManageContest"},"fetchContestInfo":{"requestType":"ReqCommon","responseType":"ResManageContest"},"exitManageContest":{"requestType":"ReqCommon","responseType":"ResCommon"},"fetchContestGameRule":{"requestType":"ReqCommon","responseType":"ResFetchContestGameRule"},"updateContestGameRule":{"requestType":"ReqUpdateContestGameRule","responseType":"ResCommon"},"searchAccountByNickname":{"requestType":"ReqSearchAccountByNickname","responseType":"ResSearchAccountByNickname"},"searchAccountByEid":{"requestType":"ReqSearchAccountByEid","responseType":"ResSearchAccountByEid"},"fetchContestPlayer":{"requestType":"ReqCommon","responseType":"ResFetchCustomizedContestPlayer"},"updateContestPlayer":{"requestType":"ReqUpdateCustomizedContestPlayer","responseType":"ResCommon"},"startManageGame":{"requestType":"ReqCommon","responseType":"ResStartManageGame"},"stopManageGame":{"requestType":"ReqCommon","responseType":"ResCommon"},"lockGamePlayer":{"requestType":"ReqLockGamePlayer","responseType":"ResCommon"},"unlockGamePlayer":{"requestType":"ReqUnlockGamePlayer","responseType":"ResCommon"},"createContestGame":{"requestType":"ReqCreateContestGame","responseType":"ResCreateContestGame"},"fetchContestGameRecords":{"requestType":"ReqFetchCustomizedContestGameRecordList","responseType":"ResFetchCustomizedContestGameRecordList"},"removeContestGameRecord":{"requestType":"ReqRemoveContestGameRecord","responseType":"ResCommon"},"fetchContestNotice":{"requestType":"ReqFetchContestNotice","responseType":"ResFetchContestNotice"},"updateContestNotice":{"requestType":"ReqUpdateCustomizedContestNotice","responseType":"ResCommon"},"fetchContestManager":{"requestType":"ReqCommon","responseType":"ResFetchCustomizedContestManager"},"updateContestManager":{"requestType":"ReqUpdateCustomizedContestManager","responseType":"ResCommon"},"fetchChatSetting":{"requestType":"ReqCommon","responseType":"ResCustomizedContestChatInfo"},"updateChatSetting":{"requestType":"ReqUpdateCustomizedContestChatSetting","responseType":"ResUpdateCustomizedContestChatSetting"},"updateGameTag":{"requestType":"ReqUpdateGameTag","responseType":"ResCommon"},"terminateGame":{"requestType":"ReqTerminateContestGame","responseType":"ResCommon"},"pauseGame":{"requestType":"ReqPauseContestGame","responseType":"ResCommon"},"resumeGame":{"requestType":"ReqResumeContestGame","responseType":"ResCommon"},"fetchCurrentRankList":{"requestType":"ReqCommon","responseType":"ResFetchCurrentRankList"},"fetchContestLastModify":{"requestType":"ReqCommon","responseType":"ResFetchContestLastModify"},"fetchContestObserver":{"requestType":"ReqCommon","responseType":"ResFetchContestObserver"},"addContestObserver":{"requestType":"ReqAddContestObserver","responseType":"ResAddContestObserver"},"removeContestObserver":{"requestType":"ReqRemoveContestObserver","responseType":"ResCommon"},"fetchContestChatHistory":{"requestType":"ReqCommon","responseType":"ResFetchContestChatHistory"},"clearChatHistory":{"requestType":"ReqClearChatHistory","responseType":"ResCommon"}}},"CustomizedContest":{"fields":{"unique_id":{"type":"uint32","id":1},"creator_id":{"type":"uint32","id":2},"contest_id":{"type":"uint32","id":3},"contest_name":{"type":"string","id":4},"state":{"type":"uint32","id":5},"create_time":{"type":"uint32","id":6},"start_time":{"type":"uint32","id":7},"finish_time":{"type":"uint32","id":8},"open":{"type":"bool","id":9},"rank_rule":{"type":"uint32","id":10},"deadline":{"type":"uint32","id":11},"auto_match":{"type":"bool","id":12},"auto_disable_end_chat":{"type":"bool","id":13},"contest_type":{"type":"uint32","id":14},"hidden_zones":{"rule":"repeated","type":"uint32","id":15},"banned_zones":{"rule":"repeated","type":"uint32","id":16},"observer_switch":{"type":"uint32","id":17},"emoji_switch":{"type":"uint32","id":18},"player_roster_type":{"type":"uint32","id":19}}},"ContestGameInfo":{"fields":{"game_uuid":{"type":"string","id":1},"players":{"rule":"repeated","type":"Player","id":2},"start_time":{"type":"uint32","id":3},"end_time":{"type":"uint32","id":4}},"nested":{"Player":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2}}}}},"ContestPlayerInfo":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2}}},"ContestMatchingPlayer":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2},"controller":{"type":"Controller","id":3}},"nested":{"Controller":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2}}}}},"ReqContestManageLogin":{"fields":{"account":{"type":"string","id":1},"password":{"type":"string","id":2},"gen_access_token":{"type":"bool","id":3},"type":{"type":"uint32","id":4}}},"ResContestManageLogin":{"fields":{"error":{"type":"Error","id":1},"account_id":{"type":"uint32","id":2},"nickname":{"type":"string","id":3},"access_token":{"type":"string","id":4},"diamond":{"type":"uint32","id":5},"last_create_time":{"type":"uint32","id":6}}},"ReqContestManageOauth2Auth":{"fields":{"type":{"type":"uint32","id":1},"code":{"type":"string","id":2},"uid":{"type":"string","id":3}}},"ResContestManageOauth2Auth":{"fields":{"error":{"type":"Error","id":1},"access_token":{"type":"string","id":2}}},"ReqContestManageOauth2Login":{"fields":{"type":{"type":"uint32","id":1},"access_token":{"type":"string","id":2},"reconnect":{"type":"bool","id":3}}},"ResContestManageOauth2Login":{"fields":{"error":{"type":"Error","id":1},"account_id":{"type":"uint32","id":2},"nickname":{"type":"string","id":3},"access_token":{"type":"string","id":4},"diamond":{"type":"uint32","id":5},"last_create_time":{"type":"uint32","id":6}}},"ResFetchRelatedContestList":{"fields":{"error":{"type":"Error","id":1},"contests":{"rule":"repeated","type":"CustomizedContest","id":2}}},"ReqCreateCustomizedContest":{"fields":{"contest_name":{"type":"string","id":1},"start_time":{"type":"uint32","id":2},"finish_time":{"type":"uint32","id":3},"open":{"type":"bool","id":4},"rank_rule":{"type":"uint32","id":5},"game_rule_setting":{"type":"GameRuleSetting","id":6}}},"ResCreateCustomizedContest":{"fields":{"error":{"type":"Error","id":1},"contest":{"type":"CustomizedContest","id":2},"diamond":{"type":"uint32","id":3}}},"ReqDeleteCustomizedContest":{"fields":{"unique_id":{"type":"uint32","id":1}}},"ReqProlongContest":{"fields":{"unique_id":{"type":"uint32","id":1}}},"ResProlongContest":{"fields":{"error":{"type":"Error","id":1},"deadline":{"type":"uint32","id":2}}},"ReqManageContest":{"fields":{"unique_id":{"type":"uint32","id":1}}},"ResManageContest":{"fields":{"error":{"type":"Error","id":1},"contest":{"type":"CustomizedContest","id":2}}},"ResFetchContestGameRule":{"fields":{"error":{"type":"Error","id":1},"game_rule_setting":{"type":"GameRuleSetting","id":2}}},"ReqUpdateContestGameRule":{"fields":{"contest_name":{"type":"string","id":1},"start_time":{"type":"uint32","id":2},"finish_time":{"type":"uint32","id":3},"open":{"type":"bool","id":4},"rank_rule":{"type":"uint32","id":5},"game_rule_setting":{"type":"GameRuleSetting","id":6},"auto_match":{"type":"bool","id":7},"auto_disable_end_chat":{"type":"bool","id":8},"contest_type":{"type":"uint32","id":9},"banned_zones":{"type":"string","id":10},"hidden_zones":{"type":"string","id":11},"emoji_switch":{"type":"bool","id":12},"player_roster_type":{"type":"uint32","id":13}}},"ReqSearchAccountByNickname":{"fields":{"query_nicknames":{"rule":"repeated","type":"string","id":1}}},"ResSearchAccountByNickname":{"fields":{"error":{"type":"Error","id":1},"search_result":{"rule":"repeated","type":"Item","id":3}},"nested":{"Item":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2}}}}},"ReqSearchAccountByEid":{"fields":{"eids":{"rule":"repeated","type":"uint32","id":1}}},"ResSearchAccountByEid":{"fields":{"error":{"type":"Error","id":1},"search_result":{"rule":"repeated","type":"Item","id":3}},"nested":{"Item":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2}}}}},"ResFetchCustomizedContestPlayer":{"fields":{"error":{"type":"Error","id":1},"players":{"rule":"repeated","type":"ContestPlayerInfo","id":2}}},"ReqUpdateCustomizedContestPlayer":{"fields":{"setting_type":{"type":"uint32","id":1},"nicknames":{"rule":"repeated","type":"string","id":2},"account_ids":{"rule":"repeated","type":"uint32","id":3}}},"ResUpdateCustomizedContestPlayer":{"fields":{"error":{"type":"Error","id":1},"failed_index":{"rule":"repeated","type":"uint32","id":2}}},"ResStartManageGame":{"fields":{"error":{"type":"Error","id":1},"players":{"rule":"repeated","type":"ContestMatchingPlayer","id":2},"games":{"rule":"repeated","type":"ContestGameInfo","id":3}}},"ReqLockGamePlayer":{"fields":{"account_id":{"type":"uint32","id":1}}},"ReqUnlockGamePlayer":{"fields":{"account_id":{"type":"uint32","id":1}}},"ReqCreateContestGame":{"fields":{"slots":{"rule":"repeated","type":"Slot","id":1},"tag":{"type":"string","id":2},"random_position":{"type":"bool","id":3},"open_live":{"type":"bool","id":4},"chat_broadcast_for_end":{"type":"bool","id":5},"ai_level":{"type":"uint32","id":6}},"nested":{"Slot":{"fields":{"account_id":{"type":"uint32","id":1},"start_point":{"type":"uint32","id":2},"seat":{"type":"uint32","id":3}}}}},"ResCreateContestGame":{"fields":{"error":{"type":"Error","id":1},"game_uuid":{"type":"string","id":2}}},"ReqFetchCustomizedContestGameRecordList":{"fields":{"last_index":{"type":"uint32","id":2}}},"ResFetchCustomizedContestGameRecordList":{"fields":{"error":{"type":"Error","id":1},"next_index":{"type":"uint32","id":2},"record_list":{"rule":"repeated","type":"Item","id":3}},"nested":{"Item":{"fields":{"record":{"type":"RecordGame","id":1},"tag":{"type":"string","id":2}}}}},"ReqRemoveContestGameRecord":{"fields":{"uuid":{"type":"string","id":1}}},"ReqFetchContestNotice":{"fields":{"notice_types":{"rule":"repeated","type":"uint32","id":1}}},"ResFetchContestNotice":{"fields":{"error":{"type":"Error","id":1},"notices":{"rule":"repeated","type":"string","id":2}}},"ReqUpdateCustomizedContestNotice":{"fields":{"notice_type":{"type":"uint32","id":1},"content":{"type":"string","id":2}}},"ResFetchCustomizedContestManager":{"fields":{"error":{"type":"Error","id":1},"players":{"rule":"repeated","type":"ContestPlayerInfo","id":2}}},"ReqUpdateCustomizedContestManager":{"fields":{"setting_type":{"type":"uint32","id":1},"nicknames":{"rule":"repeated","type":"string","id":2},"account_ids":{"rule":"repeated","type":"uint32","id":3}}},"ResCustomizedContestChatInfo":{"fields":{"error":{"type":"Error","id":1},"chat_limit_type":{"type":"uint32","id":2},"chat_limit_roster":{"rule":"repeated","type":"Item","id":3}},"nested":{"Item":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2}}}}},"ReqUpdateCustomizedContestChatSetting":{"fields":{"setting_type":{"type":"uint32","id":1},"nicknames":{"rule":"repeated","type":"string","id":2},"account_ids":{"rule":"repeated","type":"uint32","id":3},"chat_limit_type":{"type":"uint32","id":4}}},"ResUpdateCustomizedContestChatSetting":{"fields":{"error":{"type":"Error","id":1},"failed_index":{"rule":"repeated","type":"uint32","id":2}}},"ReqUpdateGameTag":{"fields":{"uuid":{"type":"string","id":1},"tag":{"type":"string","id":2}}},"ReqTerminateContestGame":{"fields":{"uuid":{"type":"string","id":1}}},"ReqPauseContestGame":{"fields":{"uuid":{"type":"string","id":1}}},"ReqResumeContestGame":{"fields":{"uuid":{"type":"string","id":1}}},"ResFetchCurrentRankList":{"fields":{"error":{"type":"Error","id":1},"rank_list":{"rule":"repeated","type":"AccountRankData","id":2},"rank_rule":{"type":"uint32","id":3}},"nested":{"AccountRankData":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2},"total_point":{"type":"int32","id":3},"total_count":{"type":"uint32","id":4}}}}},"ResFetchContestLastModify":{"fields":{"modify":{"type":"ContestLastModify","id":1}},"nested":{"ContestLastModify":{"fields":{"contest_name":{"type":"string","id":1},"external_notice":{"type":"string","id":2},"internal_notice":{"type":"string","id":3},"manager_notice":{"type":"string","id":4},"reason":{"type":"string","id":5},"status":{"type":"uint32","id":6}}}}},"ResFetchContestObserver":{"fields":{"error":{"type":"Error","id":1},"observers":{"rule":"repeated","type":"Observer","id":2}},"nested":{"Observer":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2}}}}},"ReqAddContestObserver":{"fields":{"observers":{"rule":"repeated","type":"Observer","id":1}},"nested":{"Observer":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2}}}}},"ResAddContestObserver":{"fields":{"error":{"type":"Error","id":1},"success":{"rule":"repeated","type":"Observer","id":2}},"nested":{"Observer":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2}}}}},"ReqRemoveContestObserver":{"fields":{"observers":{"rule":"repeated","type":"uint32","id":1}}},"ResFetchContestChatHistory":{"fields":{"error":{"type":"Error","id":1},"chat_history":{"rule":"repeated","type":"bytes","id":2}}},"ReqClearChatHistory":{"fields":{"unique_id":{"type":"uint32","id":1}}},"NotifyContestMatchingPlayer":{"fields":{"unique_id":{"type":"uint32","id":1},"type":{"type":"uint32","id":2},"account_id":{"type":"uint32","id":3},"nickname":{"type":"string","id":4}}},"NotifyContestMatchingPlayerLock":{"fields":{"unique_id":{"type":"uint32","id":1},"type":{"type":"uint32","id":2},"account_id":{"type":"uint32","id":3},"manager_id":{"type":"uint32","id":4}}},"NotifyContestGameStart":{"fields":{"unique_id":{"type":"uint32","id":1},"game_info":{"type":"ContestGameInfo","id":2}}},"NotifyContestGameEnd":{"fields":{"unique_id":{"type":"uint32","id":1},"game_uuid":{"type":"string","id":2}}},"NotifyContestNoticeUpdate":{"fields":{"unique_id":{"type":"uint32","id":1},"notice_type":{"type":"uint32","id":2},"content":{"type":"string","id":3}}},"NotifyContestManagerKick":{"fields":{"reason":{"type":"uint32","id":1}}},"Error":{"fields":{"code":{"type":"uint32","id":1},"u32_params":{"rule":"repeated","type":"uint32","id":2},"str_params":{"rule":"repeated","type":"string","id":3},"json_param":{"type":"string","id":4}}},"Wrapper":{"fields":{"name":{"type":"string","id":1},"data":{"type":"bytes","id":2}}},"NetworkEndpoint":{"fields":{"family":{"type":"string","id":1},"address":{"type":"string","id":2},"port":{"type":"uint32","id":3}}},"ReqCommon":{"fields":{}},"ResCommon":{"fields":{"error":{"type":"Error","id":1}}},"ResAccountUpdate":{"fields":{"error":{"type":"Error","id":1},"update":{"type":"AccountUpdate","id":2}}},"AntiAddiction":{"fields":{"online_duration":{"type":"uint32","id":1}}},"AccountMahjongStatistic":{"fields":{"final_position_counts":{"rule":"repeated","type":"uint32","id":1},"recent_round":{"type":"RoundSummary","id":2},"recent_hu":{"type":"HuSummary","id":3},"highest_hu":{"type":"HighestHuRecord","id":4},"recent_20_hu_summary":{"type":"Liqi20Summary","id":6},"recent_10_hu_summary":{"type":"LiQi10Summary","id":7},"recent_10_game_result":{"rule":"repeated","type":"GameResult","id":8}},"nested":{"RoundSummary":{"fields":{"total_count":{"type":"uint32","id":1},"rong_count":{"type":"uint32","id":2},"zimo_count":{"type":"uint32","id":3},"fangchong_count":{"type":"uint32","id":4}}},"HuSummary":{"fields":{"total_count":{"type":"uint32","id":1},"dora_round_count":{"type":"uint32","id":2},"total_fan":{"type":"uint32","id":3}}},"HighestHuRecord":{"fields":{"fanshu":{"type":"uint32","id":1},"doranum":{"type":"uint32","id":2},"title":{"type":"string","id":3},"hands":{"rule":"repeated","type":"string","id":4},"ming":{"rule":"repeated","type":"string","id":5},"hupai":{"type":"string","id":6},"title_id":{"type":"uint32","id":7}}},"Liqi20Summary":{"fields":{"total_count":{"type":"uint32","id":1},"total_lidora_count":{"type":"uint32","id":2},"average_hu_point":{"type":"uint32","id":3}}},"LiQi10Summary":{"fields":{"total_xuanshang":{"type":"uint32","id":1},"total_fanshu":{"type":"uint32","id":2}}},"GameResult":{"fields":{"rank":{"type":"uint32","id":1},"final_point":{"type":"int32","id":2}}}}},"AccountStatisticData":{"fields":{"mahjong_category":{"type":"uint32","id":1},"game_category":{"type":"uint32","id":2},"statistic":{"type":"AccountMahjongStatistic","id":3},"game_type":{"type":"uint32","id":4}}},"AccountLevel":{"fields":{"id":{"type":"uint32","id":1},"score":{"type":"uint32","id":2}}},"ViewSlot":{"fields":{"slot":{"type":"uint32","id":1},"item_id":{"type":"uint32","id":2}}},"Account":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2},"login_time":{"type":"uint32","id":3},"logout_time":{"type":"uint32","id":4},"room_id":{"type":"uint32","id":5},"anti_addiction":{"type":"AntiAddiction","id":6},"title":{"type":"uint32","id":7},"signature":{"type":"string","id":8},"email":{"type":"string","id":9},"email_verify":{"type":"uint32","id":10},"gold":{"type":"uint32","id":11},"diamond":{"type":"uint32","id":12},"avatar_id":{"type":"uint32","id":13},"vip":{"type":"uint32","id":14},"birthday":{"type":"int32","id":15},"phone":{"type":"string","id":16},"phone_verify":{"type":"uint32","id":17},"platform_diamond":{"rule":"repeated","type":"PlatformDiamond","id":18},"level":{"type":"AccountLevel","id":21},"level3":{"type":"AccountLevel","id":22},"avatar_frame":{"type":"uint32","id":23},"skin_ticket":{"type":"uint32","id":24},"platform_skin_ticket":{"rule":"repeated","type":"PlatformSkinTicket","id":25},"verified":{"type":"uint32","id":26},"challenge_levels":{"rule":"repeated","type":"ChallengeLevel","id":27},"achievement_count":{"rule":"repeated","type":"AchievementCount","id":28},"frozen_state":{"type":"uint32","id":29}},"nested":{"PlatformDiamond":{"fields":{"id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2}}},"PlatformSkinTicket":{"fields":{"id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2}}},"ChallengeLevel":{"fields":{"season":{"type":"uint32","id":1},"level":{"type":"uint32","id":2},"rank":{"type":"uint32","id":3}}},"AchievementCount":{"fields":{"rare":{"type":"uint32","id":1},"count":{"type":"uint32","id":2}}}}},"AccountOwnerData":{"fields":{"unlock_characters":{"rule":"repeated","type":"uint32","id":1}}},"AccountUpdate":{"fields":{"numerical":{"rule":"repeated","type":"NumericalUpdate","id":1},"character":{"type":"CharacterUpdate","id":2},"bag":{"type":"BagUpdate","id":3},"achievement":{"type":"AchievementUpdate","id":4},"shilian":{"type":"AccountShiLian","id":5},"daily_task":{"type":"DailyTaskUpdate","id":6},"title":{"type":"TitleUpdate","id":7},"new_recharged_list":{"rule":"repeated","type":"uint32","id":8},"activity_task":{"type":"TaskUpdate","id":9},"activity_flip_task":{"type":"TaskUpdate","id":10},"activity_period_task":{"type":"TaskUpdate","id":11},"activity_random_task":{"type":"TaskUpdate","id":12},"challenge":{"type":"AccountChallengeUpdate","id":13},"ab_match":{"type":"AccountABMatchUpdate","id":14},"activity":{"type":"lq.AccountActivityUpdate","id":15},"activity_segment_task":{"type":"SegmentTaskUpdate","id":16}},"nested":{"NumericalUpdate":{"fields":{"id":{"type":"uint32","id":1},"final":{"type":"uint32","id":3}}},"CharacterUpdate":{"fields":{"characters":{"rule":"repeated","type":"Character","id":2},"skins":{"rule":"repeated","type":"uint32","id":3},"finished_endings":{"rule":"repeated","type":"uint32","id":4},"rewarded_endings":{"rule":"repeated","type":"uint32","id":5}}},"AchievementUpdate":{"fields":{"progresses":{"rule":"repeated","type":"AchievementProgress","id":1},"rewarded_group":{"rule":"repeated","type":"uint32","id":2}}},"DailyTaskUpdate":{"fields":{"progresses":{"rule":"repeated","type":"TaskProgress","id":1},"task_list":{"rule":"repeated","type":"uint32","id":2}}},"TitleUpdate":{"fields":{"new_titles":{"rule":"repeated","type":"uint32","id":1},"remove_titles":{"rule":"repeated","type":"uint32","id":2}}},"TaskUpdate":{"fields":{"progresses":{"rule":"repeated","type":"TaskProgress","id":1},"task_list":{"rule":"repeated","type":"uint32","id":2}}},"AccountChallengeUpdate":{"fields":{"progresses":{"rule":"repeated","type":"TaskProgress","id":1},"level":{"type":"uint32","id":2},"refresh_count":{"type":"uint32","id":3},"match_count":{"type":"uint32","id":4},"ticket_id":{"type":"uint32","id":5},"task_list":{"rule":"repeated","type":"uint32","id":6},"rewarded_season":{"rule":"repeated","type":"uint32","id":7}}},"AccountABMatchUpdate":{"fields":{"match_id":{"type":"uint32","id":1},"match_count":{"type":"uint32","id":2},"buy_in_count":{"type":"uint32","id":3},"point":{"type":"uint32","id":4},"rewarded":{"type":"bool","id":5},"match_max_point":{"rule":"repeated","type":"MatchPoint","id":6},"quit":{"type":"bool","id":7}},"nested":{"MatchPoint":{"fields":{"match_id":{"type":"uint32","id":1},"point":{"type":"uint32","id":2}}}}},"SegmentTaskUpdate":{"fields":{"progresses":{"rule":"repeated","type":"lq.SegmentTaskProgress","id":1},"task_list":{"rule":"repeated","type":"uint32","id":2}}}}},"GameMetaData":{"fields":{"room_id":{"type":"uint32","id":1},"mode_id":{"type":"uint32","id":2},"contest_uid":{"type":"uint32","id":3}}},"AccountPlayingGame":{"fields":{"game_uuid":{"type":"string","id":1},"category":{"type":"uint32","id":2},"meta":{"type":"GameMetaData","id":3}}},"AccountCacheView":{"fields":{"cache_version":{"type":"uint32","id":1},"account_id":{"type":"uint32","id":2},"nickname":{"type":"string","id":3},"login_time":{"type":"uint32","id":4},"logout_time":{"type":"uint32","id":5},"is_online":{"type":"bool","id":6},"room_id":{"type":"uint32","id":7},"title":{"type":"uint32","id":8},"avatar_id":{"type":"uint32","id":9},"vip":{"type":"uint32","id":10},"level":{"type":"AccountLevel","id":11},"playing_game":{"type":"AccountPlayingGame","id":12},"level3":{"type":"AccountLevel","id":13},"avatar_frame":{"type":"uint32","id":14},"verified":{"type":"uint32","id":15},"ban_deadline":{"type":"uint32","id":16},"comment_ban":{"type":"uint32","id":17},"ban_state":{"type":"uint32","id":18}}},"PlayerBaseView":{"fields":{"account_id":{"type":"uint32","id":1},"avatar_id":{"type":"uint32","id":2},"title":{"type":"uint32","id":3},"nickname":{"type":"string","id":4},"level":{"type":"AccountLevel","id":5},"level3":{"type":"AccountLevel","id":6},"avatar_frame":{"type":"uint32","id":7},"verified":{"type":"uint32","id":8},"is_banned":{"type":"uint32","id":9}}},"PlayerGameView":{"fields":{"account_id":{"type":"uint32","id":1},"avatar_id":{"type":"uint32","id":2},"title":{"type":"uint32","id":3},"nickname":{"type":"string","id":4},"level":{"type":"AccountLevel","id":5},"character":{"type":"Character","id":6},"level3":{"type":"AccountLevel","id":7},"avatar_frame":{"type":"uint32","id":8},"verified":{"type":"uint32","id":9},"views":{"rule":"repeated","type":"ViewSlot","id":10}}},"GameSetting":{"fields":{"emoji_switch":{"type":"uint32","id":1}}},"GameMode":{"fields":{"mode":{"type":"uint32","id":1},"ai":{"type":"bool","id":4},"extendinfo":{"type":"string","id":5},"detail_rule":{"type":"GameDetailRule","id":6},"testing_environment":{"type":"GameTestingEnvironmentSet","id":7},"game_setting":{"type":"GameSetting","id":8}}},"GameTestingEnvironmentSet":{"fields":{"paixing":{"type":"uint32","id":1},"left_count":{"type":"uint32","id":2}}},"GameDetailRule":{"fields":{"time_fixed":{"type":"uint32","id":1},"time_add":{"type":"uint32","id":2},"dora_count":{"type":"uint32","id":3},"shiduan":{"type":"uint32","id":4},"init_point":{"type":"uint32","id":5},"fandian":{"type":"uint32","id":6},"can_jifei":{"type":"bool","id":7},"tianbian_value":{"type":"uint32","id":8},"liqibang_value":{"type":"uint32","id":9},"changbang_value":{"type":"uint32","id":10},"noting_fafu_1":{"type":"uint32","id":11},"noting_fafu_2":{"type":"uint32","id":12},"noting_fafu_3":{"type":"uint32","id":13},"have_liujumanguan":{"type":"bool","id":14},"have_qieshangmanguan":{"type":"bool","id":15},"have_biao_dora":{"type":"bool","id":16},"have_gang_biao_dora":{"type":"bool","id":17},"ming_dora_immediately_open":{"type":"bool","id":18},"have_li_dora":{"type":"bool","id":19},"have_gang_li_dora":{"type":"bool","id":20},"have_sifenglianda":{"type":"bool","id":21},"have_sigangsanle":{"type":"bool","id":22},"have_sijializhi":{"type":"bool","id":23},"have_jiuzhongjiupai":{"type":"bool","id":24},"have_sanjiahele":{"type":"bool","id":25},"have_toutiao":{"type":"bool","id":26},"have_helelianzhuang":{"type":"bool","id":27},"have_helezhongju":{"type":"bool","id":28},"have_tingpailianzhuang":{"type":"bool","id":29},"have_tingpaizhongju":{"type":"bool","id":30},"have_yifa":{"type":"bool","id":31},"have_nanruxiru":{"type":"bool","id":32},"jingsuanyuandian":{"type":"uint32","id":33},"shunweima_2":{"type":"int32","id":34},"shunweima_3":{"type":"int32","id":35},"shunweima_4":{"type":"int32","id":36},"bianjietishi":{"type":"bool","id":37},"ai_level":{"type":"uint32","id":38},"have_zimosun":{"type":"bool","id":39},"disable_multi_yukaman":{"type":"bool","id":40},"fanfu":{"type":"uint32","id":41},"guyi_mode":{"type":"uint32","id":42},"dora3_mode":{"type":"uint32","id":43},"begin_open_mode":{"type":"uint32","id":44},"jiuchao_mode":{"type":"uint32","id":45},"muyu_mode":{"type":"uint32","id":46},"open_hand":{"type":"uint32","id":47},"xuezhandaodi":{"type":"uint32","id":48},"huansanzhang":{"type":"uint32","id":49},"chuanma":{"type":"uint32","id":50},"reveal_discard":{"type":"uint32","id":51},"disable_leijiyiman":{"type":"bool","id":60}}},"Room":{"fields":{"room_id":{"type":"uint32","id":1},"owner_id":{"type":"uint32","id":2},"mode":{"type":"GameMode","id":3},"max_player_count":{"type":"uint32","id":4},"persons":{"rule":"repeated","type":"PlayerGameView","id":5},"ready_list":{"rule":"repeated","type":"uint32","id":6},"is_playing":{"type":"bool","id":7},"public_live":{"type":"bool","id":8},"robot_count":{"type":"uint32","id":9},"tournament_id":{"type":"uint32","id":10},"seq":{"type":"uint32","id":11}}},"GameEndResult":{"fields":{"players":{"rule":"repeated","type":"PlayerItem","id":1}},"nested":{"PlayerItem":{"fields":{"seat":{"type":"uint32","id":1},"total_point":{"type":"int32","id":2},"part_point_1":{"type":"int32","id":3},"part_point_2":{"type":"int32","id":4},"grading_score":{"type":"int32","id":5},"gold":{"type":"int32","id":6}}}}},"GameConnectInfo":{"fields":{"connect_token":{"type":"string","id":2},"game_uuid":{"type":"string","id":3},"location":{"type":"string","id":4}}},"ItemGainRecord":{"fields":{"item_id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2}}},"ItemGainRecords":{"fields":{"record_time":{"type":"uint32","id":1},"limit_source_id":{"type":"uint32","id":2},"records":{"rule":"repeated","type":"ItemGainRecord","id":3}}},"FakeRandomRecords":{"fields":{"item_id":{"type":"uint32","id":1},"special_item_id":{"type":"uint32","id":2},"gain_count":{"type":"uint32","id":3},"gain_history":{"rule":"repeated","type":"uint32","id":4}}},"Item":{"fields":{"item_id":{"type":"uint32","id":1},"stack":{"type":"uint32","id":2}}},"Bag":{"fields":{"items":{"rule":"repeated","type":"Item","id":1},"daily_gain_record":{"rule":"repeated","type":"ItemGainRecords","id":2}}},"BagUpdate":{"fields":{"update_items":{"rule":"repeated","type":"Item","id":1},"update_daily_gain_record":{"rule":"repeated","type":"ItemGainRecords","id":2}}},"RewardSlot":{"fields":{"id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2}}},"OpenResult":{"fields":{"reward":{"type":"RewardSlot","id":1},"replace":{"type":"RewardSlot","id":2}}},"RewardPlusResult":{"fields":{"id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2},"exchange":{"type":"Exchange","id":3}},"nested":{"Exchange":{"fields":{"id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2},"exchange":{"type":"uint32","id":3}}}}},"ExecuteReward":{"fields":{"reward":{"type":"RewardSlot","id":1},"replace":{"type":"RewardSlot","id":2},"replace_count":{"type":"uint32","id":3}}},"I18nContext":{"fields":{"lang":{"type":"string","id":1},"context":{"type":"string","id":2}}},"Mail":{"fields":{"mail_id":{"type":"uint32","id":1},"state":{"type":"uint32","id":2},"take_attachment":{"type":"bool","id":3},"title":{"type":"string","id":4},"content":{"type":"string","id":5},"attachments":{"rule":"repeated","type":"RewardSlot","id":6},"create_time":{"type":"uint32","id":7},"expire_time":{"type":"uint32","id":8},"reference_id":{"type":"uint32","id":9},"title_i18n":{"rule":"repeated","type":"I18nContext","id":10},"content_i18n":{"rule":"repeated","type":"I18nContext","id":11}}},"AchievementProgress":{"fields":{"id":{"type":"uint32","id":1},"counter":{"type":"uint32","id":2},"achieved":{"type":"bool","id":3},"rewarded":{"type":"bool","id":4},"achieved_time":{"type":"uint32","id":5}}},"AccountStatisticByGameMode":{"fields":{"mode":{"type":"uint32","id":1},"game_count_sum":{"type":"uint32","id":2},"game_final_position":{"rule":"repeated","type":"uint32","id":3},"fly_count":{"type":"uint32","id":4},"gold_earn_sum":{"type":"float","id":5},"round_count_sum":{"type":"uint32","id":6},"dadian_sum":{"type":"float","id":7},"round_end":{"rule":"repeated","type":"RoundEndData","id":8},"ming_count_sum":{"type":"uint32","id":9},"liqi_count_sum":{"type":"uint32","id":10},"xun_count_sum":{"type":"uint32","id":11},"highest_lianzhuang":{"type":"uint32","id":12},"score_earn_sum":{"type":"uint32","id":13},"rank_score":{"rule":"repeated","type":"RankScore","id":14}},"nested":{"RoundEndData":{"fields":{"type":{"type":"uint32","id":1},"sum":{"type":"uint32","id":2}}},"RankScore":{"fields":{"rank":{"type":"uint32","id":1},"score_sum":{"type":"int32","id":2},"count":{"type":"uint32","id":3}}}}},"AccountStatisticByFan":{"fields":{"fan_id":{"type":"uint32","id":1},"sum":{"type":"uint32","id":2}}},"AccountFanAchieved":{"fields":{"mahjong_category":{"type":"uint32","id":1},"fan":{"rule":"repeated","type":"AccountStatisticByFan","id":2},"liujumanguan":{"type":"uint32","id":3}}},"AccountDetailStatistic":{"fields":{"game_mode":{"rule":"repeated","type":"AccountStatisticByGameMode","id":1},"fan":{"rule":"repeated","type":"AccountStatisticByFan","id":2},"liujumanguan":{"type":"uint32","id":3},"fan_achieved":{"rule":"repeated","type":"AccountFanAchieved","id":4}}},"AccountDetailStatisticByCategory":{"fields":{"category":{"type":"uint32","id":1},"detail_statistic":{"type":"AccountDetailStatistic","id":2}}},"AccountDetailStatisticV2":{"fields":{"friend_room_statistic":{"type":"AccountDetailStatistic","id":1},"rank_statistic":{"type":"RankStatistic","id":2},"customized_contest_statistic":{"type":"CustomizedContestStatistic","id":3},"leisure_match_statistic":{"type":"AccountDetailStatistic","id":4},"challenge_match_statistic":{"type":"ChallengeStatistic","id":5},"activity_match_statistic":{"type":"AccountDetailStatistic","id":6},"ab_match_statistic":{"type":"AccountDetailStatistic","id":7}},"nested":{"RankStatistic":{"fields":{"total_statistic":{"type":"RankData","id":1},"month_statistic":{"type":"RankData","id":2},"month_refresh_time":{"type":"uint32","id":3}},"nested":{"RankData":{"fields":{"all_level_statistic":{"type":"AccountDetailStatistic","id":1},"level_data_list":{"rule":"repeated","type":"RankLevelData","id":2}},"nested":{"RankLevelData":{"fields":{"rank_level":{"type":"uint32","id":1},"statistic":{"type":"AccountDetailStatistic","id":2}}}}}}},"CustomizedContestStatistic":{"fields":{"total_statistic":{"type":"AccountDetailStatistic","id":1},"month_statistic":{"type":"AccountDetailStatistic","id":2},"month_refresh_time":{"type":"uint32","id":3}}},"ChallengeStatistic":{"fields":{"all_season":{"type":"AccountDetailStatistic","id":1},"season_data_list":{"rule":"repeated","type":"SeasonData","id":2}},"nested":{"SeasonData":{"fields":{"season_id":{"type":"uint32","id":1},"statistic":{"type":"AccountDetailStatistic","id":2}}}}}}},"AccountShiLian":{"fields":{"step":{"type":"uint32","id":1},"state":{"type":"uint32","id":2}}},"ClientDeviceInfo":{"fields":{"platform":{"type":"string","id":1},"hardware":{"type":"string","id":2},"os":{"type":"string","id":3},"os_version":{"type":"string","id":4},"is_browser":{"type":"bool","id":5},"software":{"type":"string","id":6},"sale_platform":{"type":"string","id":7},"hardware_vendor":{"type":"string","id":8},"model_number":{"type":"string","id":9}}},"ClientVersionInfo":{"fields":{"resource":{"type":"string","id":1},"package":{"type":"string","id":2}}},"GamePlayerState":{"values":{"NULL":0,"AUTH":1,"SYNCING":2,"READY":3}},"Announcement":{"fields":{"id":{"type":"uint32","id":1},"title":{"type":"string","id":2},"content":{"type":"string","id":3}}},"TaskProgress":{"fields":{"id":{"type":"uint32","id":1},"counter":{"type":"uint32","id":2},"achieved":{"type":"bool","id":3},"rewarded":{"type":"bool","id":4},"failed":{"type":"bool","id":5}}},"GameConfig":{"fields":{"category":{"type":"uint32","id":1},"mode":{"type":"GameMode","id":2},"meta":{"type":"GameMetaData","id":3}}},"RPGState":{"fields":{"player_damaged":{"type":"uint32","id":1},"monster_damaged":{"type":"uint32","id":2},"monster_seq":{"type":"uint32","id":3}}},"RPGActivity":{"fields":{"activity_id":{"type":"uint32","id":1},"last_show_uuid":{"type":"string","id":5},"last_played_uuid":{"type":"string","id":6},"current_state":{"type":"RPGState","id":7},"last_show_state":{"type":"RPGState","id":8},"received_rewards":{"rule":"repeated","type":"uint32","id":9}}},"ActivityArenaData":{"fields":{"win_count":{"type":"uint32","id":1},"lose_count":{"type":"uint32","id":2},"activity_id":{"type":"uint32","id":3},"enter_time":{"type":"uint32","id":4},"daily_enter_count":{"type":"uint32","id":5},"daily_enter_time":{"type":"uint32","id":6},"max_win_count":{"type":"uint32","id":7},"total_win_count":{"type":"uint32","id":8}}},"FeedActivityData":{"fields":{"activity_id":{"type":"uint32","id":1},"feed_count":{"type":"uint32","id":2},"friend_receive_data":{"type":"CountWithTimeData","id":3},"friend_send_data":{"type":"CountWithTimeData","id":4},"gift_inbox":{"rule":"repeated","type":"GiftBoxData","id":5}},"nested":{"CountWithTimeData":{"fields":{"count":{"type":"uint32","id":1},"last_update_time":{"type":"uint32","id":2}}},"GiftBoxData":{"fields":{"id":{"type":"uint32","id":1},"item_id":{"type":"uint32","id":2},"count":{"type":"uint32","id":3},"from_account_id":{"type":"uint32","id":4},"time":{"type":"uint32","id":5},"received":{"type":"uint32","id":6}}}}},"SegmentTaskProgress":{"fields":{"id":{"type":"uint32","id":1},"counter":{"type":"uint32","id":2},"achieved":{"type":"bool","id":3},"rewarded":{"type":"bool","id":4},"failed":{"type":"bool","id":5},"reward_count":{"type":"uint32","id":6},"achieved_count":{"type":"uint32","id":7}}},"MineActivityData":{"fields":{"dig_point":{"rule":"repeated","type":"Point","id":1},"map":{"rule":"repeated","type":"MineReward","id":2},"id":{"type":"uint32","id":3}}},"AccountActivityUpdate":{"fields":{"mine_data":{"rule":"repeated","type":"lq.MineActivityData","id":1},"rpg_data":{"rule":"repeated","type":"lq.RPGActivity","id":2},"feed_data":{"rule":"repeated","type":"ActivityFeedData","id":3}}},"ActivityFeedData":{"fields":{"activity_id":{"type":"uint32","id":1},"feed_count":{"type":"uint32","id":2},"friend_receive_data":{"type":"CountWithTimeData","id":3},"friend_send_data":{"type":"CountWithTimeData","id":4},"gift_inbox":{"rule":"repeated","type":"GiftBoxData","id":5},"max_inbox_id":{"type":"uint32","id":6}},"nested":{"CountWithTimeData":{"fields":{"count":{"type":"uint32","id":1},"last_update_time":{"type":"uint32","id":2}}},"GiftBoxData":{"fields":{"id":{"type":"uint32","id":1},"item_id":{"type":"uint32","id":2},"count":{"type":"uint32","id":3},"from_account_id":{"type":"uint32","id":4},"time":{"type":"uint32","id":5},"received":{"type":"uint32","id":6}}}}},"AccountActiveState":{"fields":{"account_id":{"type":"uint32","id":1},"login_time":{"type":"uint32","id":2},"logout_time":{"type":"uint32","id":3},"is_online":{"type":"bool","id":4},"playing":{"type":"AccountPlayingGame","id":5}}},"Friend":{"fields":{"base":{"type":"PlayerBaseView","id":1},"state":{"type":"AccountActiveState","id":2}}},"Point":{"fields":{"x":{"type":"uint32","id":1},"y":{"type":"uint32","id":2}}},"MineReward":{"fields":{"point":{"type":"Point","id":1},"reward_id":{"type":"uint32","id":2},"received":{"type":"bool","id":3}}},"GameLiveUnit":{"fields":{"timestamp":{"type":"uint32","id":1},"action_category":{"type":"uint32","id":2},"action_data":{"type":"bytes","id":3}}},"GameLiveSegment":{"fields":{"actions":{"rule":"repeated","type":"GameLiveUnit","id":1}}},"GameLiveSegmentUri":{"fields":{"segment_id":{"type":"uint32","id":1},"segment_uri":{"type":"string","id":2}}},"GameLiveHead":{"fields":{"uuid":{"type":"string","id":1},"start_time":{"type":"uint32","id":2},"game_config":{"type":"GameConfig","id":3},"players":{"rule":"repeated","type":"PlayerGameView","id":4},"seat_list":{"rule":"repeated","type":"uint32","id":5}}},"GameNewRoundState":{"fields":{"seat_states":{"rule":"repeated","type":"uint32","id":1}}},"GameEndAction":{"fields":{"state":{"type":"uint32","id":1}}},"GameNoopAction":{"fields":{}},"CommentItem":{"fields":{"comment_id":{"type":"uint32","id":1},"timestamp":{"type":"uint32","id":2},"commenter":{"type":"PlayerBaseView","id":3},"content":{"type":"string","id":4},"is_banned":{"type":"uint32","id":5}}},"RollingNotice":{"fields":{"id":{"type":"uint32","id":1},"content":{"type":"string","id":2},"start_time":{"type":"uint32","id":3},"end_time":{"type":"uint32","id":4},"repeat_interval":{"type":"uint32","id":5},"lang":{"type":"string","id":6}}},"BillingGoods":{"fields":{"id":{"type":"string","id":1},"name":{"type":"string","id":2},"desc":{"type":"string","id":3},"icon":{"type":"string","id":4},"resource_id":{"type":"uint32","id":5},"resource_count":{"type":"uint32","id":6}}},"BillShortcut":{"fields":{"id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2},"dealPrice":{"type":"uint32","id":3}}},"BillingProduct":{"fields":{"goods":{"type":"BillingGoods","id":1},"currency_code":{"type":"string","id":2},"currency_price":{"type":"uint32","id":3},"sort_weight":{"type":"uint32","id":4}}},"Character":{"fields":{"charid":{"type":"uint32","id":1},"level":{"type":"uint32","id":2},"exp":{"type":"uint32","id":3},"views":{"rule":"repeated","type":"ViewSlot","id":4},"skin":{"type":"uint32","id":5},"is_upgraded":{"type":"bool","id":6},"extra_emoji":{"rule":"repeated","type":"uint32","id":7},"rewarded_level":{"rule":"repeated","type":"uint32","id":8}}},"BuyRecord":{"fields":{"id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2}}},"ZHPShop":{"fields":{"goods":{"rule":"repeated","type":"uint32","id":1},"buy_records":{"rule":"repeated","type":"BuyRecord","id":2},"free_refresh":{"type":"RefreshCount","id":3},"cost_refresh":{"type":"RefreshCount","id":4}},"nested":{"RefreshCount":{"fields":{"count":{"type":"uint32","id":1},"limit":{"type":"uint32","id":2}}}}},"MonthTicketInfo":{"fields":{"id":{"type":"uint32","id":1},"end_time":{"type":"uint32","id":2},"last_pay_time":{"type":"uint32","id":3}}},"ShopInfo":{"fields":{"zhp":{"type":"ZHPShop","id":1},"buy_records":{"rule":"repeated","type":"BuyRecord","id":2},"last_refresh_time":{"type":"uint32","id":3}}},"ChangeNicknameRecord":{"fields":{"from":{"type":"string","id":1},"to":{"type":"string","id":2},"time":{"type":"uint32","id":3}}},"ServerSettings":{"fields":{"payment_setting":{"type":"PaymentSetting","id":3},"payment_setting_v2":{"type":"PaymentSettingV2","id":4},"nickname_setting":{"type":"NicknameSetting","id":5}}},"NicknameSetting":{"fields":{"enable":{"type":"uint32","id":1},"nicknames":{"rule":"repeated","type":"string","id":2}}},"PaymentSettingV2":{"fields":{"open_payment":{"type":"uint32","id":1},"payment_platforms":{"rule":"repeated","type":"PaymentSettingUnit","id":2}},"nested":{"PaymentMaintain":{"fields":{"start_time":{"type":"uint32","id":1},"end_time":{"type":"uint32","id":2},"goods_click_action":{"type":"uint32","id":3},"goods_click_text":{"type":"string","id":4}}},"PaymentSettingUnit":{"fields":{"platform":{"type":"string","id":1},"is_show":{"type":"bool","id":2},"goods_click_action":{"type":"uint32","id":3},"goods_click_text":{"type":"string","id":4},"maintain":{"type":"PaymentMaintain","id":5},"enable_for_frozen_account":{"type":"bool","id":6}}}}},"PaymentSetting":{"fields":{"open_payment":{"type":"uint32","id":1},"payment_info_show_type":{"type":"uint32","id":2},"payment_info":{"type":"string","id":3},"wechat":{"type":"WechatData","id":4},"alipay":{"type":"AlipayData","id":5}},"nested":{"WechatData":{"fields":{"disable_create":{"type":"bool","id":1},"payment_source_platform":{"type":"uint32","id":2},"enable_credit":{"type":"bool","id":3}}},"AlipayData":{"fields":{"disable_create":{"type":"bool","id":1},"payment_source_platform":{"type":"uint32","id":2}}}}},"AccountSetting":{"fields":{"key":{"type":"uint32","id":1},"value":{"type":"uint32","id":2}}},"ChestData":{"fields":{"chest_id":{"type":"uint32","id":1},"total_open_count":{"type":"uint32","id":2},"consume_count":{"type":"uint32","id":3},"face_black_count":{"type":"uint32","id":4}}},"ChestDataV2":{"fields":{"chest_id":{"type":"uint32","id":1},"total_open_count":{"type":"uint32","id":2},"face_black_count":{"type":"uint32","id":3}}},"FaithData":{"fields":{"faith_id":{"type":"uint32","id":1},"total_open_count":{"type":"uint32","id":2},"consume_count":{"type":"uint32","id":3},"modify_count":{"type":"int32","id":4}}},"CustomizedContestBase":{"fields":{"unique_id":{"type":"uint32","id":1},"contest_id":{"type":"uint32","id":2},"contest_name":{"type":"string","id":3},"state":{"type":"uint32","id":4},"creator_id":{"type":"uint32","id":5},"create_time":{"type":"uint32","id":6},"start_time":{"type":"uint32","id":7},"finish_time":{"type":"uint32","id":8},"open":{"type":"bool","id":9},"contest_type":{"type":"uint32","id":10}}},"CustomizedContestExtend":{"fields":{"unique_id":{"type":"uint32","id":1},"public_notice":{"type":"string","id":2}}},"CustomizedContestAbstract":{"fields":{"unique_id":{"type":"uint32","id":1},"contest_id":{"type":"uint32","id":2},"contest_name":{"type":"string","id":3},"state":{"type":"uint32","id":4},"creator_id":{"type":"uint32","id":5},"create_time":{"type":"uint32","id":6},"start_time":{"type":"uint32","id":7},"finish_time":{"type":"uint32","id":8},"open":{"type":"bool","id":9},"public_notice":{"type":"string","id":10},"contest_type":{"type":"uint32","id":11}}},"CustomizedContestDetail":{"fields":{"unique_id":{"type":"uint32","id":1},"contest_id":{"type":"uint32","id":2},"contest_name":{"type":"string","id":3},"state":{"type":"uint32","id":4},"creator_id":{"type":"uint32","id":5},"create_time":{"type":"uint32","id":6},"start_time":{"type":"uint32","id":7},"finish_time":{"type":"uint32","id":8},"open":{"type":"bool","id":9},"rank_rule":{"type":"uint32","id":10},"game_mode":{"type":"GameMode","id":11},"private_notice":{"type":"string","id":12},"observer_switch":{"type":"uint32","id":13},"emoji_switch":{"type":"uint32","id":14},"contest_type":{"type":"uint32","id":15}}},"CustomizedContestPlayerReport":{"fields":{"rank_rule":{"type":"uint32","id":1},"rank":{"type":"uint32","id":2},"point":{"type":"int32","id":3},"game_ranks":{"rule":"repeated","type":"uint32","id":4},"total_game_count":{"type":"uint32","id":5}}},"RecordGame":{"fields":{"uuid":{"type":"string","id":1},"start_time":{"type":"uint32","id":2},"end_time":{"type":"uint32","id":3},"config":{"type":"GameConfig","id":5},"accounts":{"rule":"repeated","type":"AccountInfo","id":11},"result":{"type":"GameEndResult","id":12}},"nested":{"AccountInfo":{"fields":{"account_id":{"type":"uint32","id":1},"seat":{"type":"uint32","id":2},"nickname":{"type":"string","id":3},"avatar_id":{"type":"uint32","id":4},"character":{"type":"Character","id":5},"title":{"type":"uint32","id":6},"level":{"type":"AccountLevel","id":7},"level3":{"type":"AccountLevel","id":8},"avatar_frame":{"type":"uint32","id":9},"verified":{"type":"uint32","id":10},"views":{"rule":"repeated","type":"ViewSlot","id":11}}}}},"CustomizedContestGameStart":{"fields":{"players":{"rule":"repeated","type":"Item","id":1}},"nested":{"Item":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2}}}}},"CustomizedContestGameEnd":{"fields":{"players":{"rule":"repeated","type":"Item","id":1}},"nested":{"Item":{"fields":{"account_id":{"type":"uint32","id":1},"nickname":{"type":"string","id":2},"total_point":{"type":"int32","id":3}}}}},"Activity":{"fields":{"activity_id":{"type":"uint32","id":1},"start_time":{"type":"uint32","id":2},"end_time":{"type":"uint32","id":3},"type":{"type":"string","id":4}}},"ExchangeRecord":{"fields":{"exchange_id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2}}},"ActivityAccumulatedPointData":{"fields":{"activity_id":{"type":"uint32","id":1},"point":{"type":"int32","id":2},"gained_reward_list":{"rule":"repeated","type":"uint32","id":3}}},"ActivityRankPointData":{"fields":{"leaderboard_id":{"type":"uint32","id":1},"point":{"type":"int32","id":2},"gained_reward":{"type":"bool","id":3},"gainable_time":{"type":"uint32","id":4}}},"GameRoundHuData":{"fields":{"hupai":{"type":"HuPai","id":1},"fans":{"rule":"repeated","type":"Fan","id":2},"score":{"type":"uint32","id":3},"xun":{"type":"uint32","id":4},"title_id":{"type":"uint32","id":5},"fan_sum":{"type":"uint32","id":6},"fu_sum":{"type":"uint32","id":7},"yakuman_count":{"type":"uint32","id":8},"biao_dora_count":{"type":"uint32","id":9},"red_dora_count":{"type":"uint32","id":10},"li_dora_count":{"type":"uint32","id":11},"babei_count":{"type":"uint32","id":12},"xuan_shang_count":{"type":"uint32","id":13}},"nested":{"HuPai":{"fields":{"tile":{"type":"string","id":1},"seat":{"type":"uint32","id":2},"liqi":{"type":"uint32","id":3}}},"Fan":{"fields":{"id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2},"fan":{"type":"uint32","id":3}}}}},"GameRoundPlayerResult":{"fields":{"type":{"type":"uint32","id":1},"hands":{"rule":"repeated","type":"string","id":2},"ming":{"rule":"repeated","type":"string","id":3},"liqi_type":{"type":"uint32","id":4},"is_fulu":{"type":"bool","id":5},"is_liujumanguan":{"type":"bool","id":6},"lian_zhuang":{"type":"uint32","id":7},"hu":{"type":"GameRoundHuData","id":8}}},"GameRoundPlayer":{"fields":{"score":{"type":"int32","id":1},"rank":{"type":"uint32","id":2},"result":{"type":"GameRoundPlayerResult","id":3}}},"GameRoundSnapshot":{"fields":{"ju":{"type":"uint32","id":1},"ben":{"type":"uint32","id":2},"players":{"rule":"repeated","type":"GameRoundPlayer","id":3}}},"GameFinalSnapshot":{"fields":{"uuid":{"type":"string","id":1},"state":{"type":"uint32","id":2},"category":{"type":"uint32","id":3},"mode":{"type":"GameMode","id":4},"meta":{"type":"GameMetaData","id":5},"calculate_param":{"type":"CalculateParam","id":6},"create_time":{"type":"uint32","id":7},"start_time":{"type":"uint32","id":8},"finish_time":{"type":"uint32","id":9},"seats":{"rule":"repeated","type":"GameSeat","id":10},"rounds":{"rule":"repeated","type":"GameRoundSnapshot","id":11},"account_views":{"rule":"repeated","type":"PlayerGameView","id":12},"final_players":{"rule":"repeated","type":"FinalPlayer","id":13},"afk_info":{"rule":"repeated","type":"AFKInfo","id":14}},"nested":{"CalculateParam":{"fields":{"init_point":{"type":"uint32","id":1},"jingsuanyuandian":{"type":"uint32","id":2},"rank_points":{"rule":"repeated","type":"int32","id":3}}},"GameSeat":{"fields":{"type":{"type":"uint32","id":1},"account_id":{"type":"uint32","id":2},"notify_endpoint":{"type":"NetworkEndpoint","id":3},"client_address":{"type":"string","id":4},"is_connected":{"type":"bool","id":5}}},"FinalPlayer":{"fields":{"seat":{"type":"uint32","id":1},"total_point":{"type":"int32","id":2},"part_point_1":{"type":"int32","id":3},"part_point_2":{"type":"int32","id":4},"grading_score":{"type":"int32","id":5},"gold":{"type":"int32","id":6}}},"AFKInfo":{"fields":{"deal_tile_count":{"type":"uint32","id":1},"moqie_count":{"type":"uint32","id":2},"seat":{"type":"uint32","id":3}}}}},"RecordCollectedData":{"fields":{"uuid":{"type":"string","id":1},"remarks":{"type":"string","id":2},"start_time":{"type":"uint32","id":3},"end_time":{"type":"uint32","id":4}}},"ContestDetailRule":{"fields":{"init_point":{"type":"uint32","id":5},"fandian":{"type":"uint32","id":6},"can_jifei":{"type":"bool","id":7},"tianbian_value":{"type":"uint32","id":8},"liqibang_value":{"type":"uint32","id":9},"changbang_value":{"type":"uint32","id":10},"noting_fafu_1":{"type":"uint32","id":11},"noting_fafu_2":{"type":"uint32","id":12},"noting_fafu_3":{"type":"uint32","id":13},"have_liujumanguan":{"type":"bool","id":14},"have_qieshangmanguan":{"type":"bool","id":15},"have_biao_dora":{"type":"bool","id":16},"have_gang_biao_dora":{"type":"bool","id":17},"ming_dora_immediately_open":{"type":"bool","id":18},"have_li_dora":{"type":"bool","id":19},"have_gang_li_dora":{"type":"bool","id":20},"have_sifenglianda":{"type":"bool","id":21},"have_sigangsanle":{"type":"bool","id":22},"have_sijializhi":{"type":"bool","id":23},"have_jiuzhongjiupai":{"type":"bool","id":24},"have_sanjiahele":{"type":"bool","id":25},"have_toutiao":{"type":"bool","id":26},"have_helelianzhuang":{"type":"bool","id":27},"have_helezhongju":{"type":"bool","id":28},"have_tingpailianzhuang":{"type":"bool","id":29},"have_tingpaizhongju":{"type":"bool","id":30},"have_yifa":{"type":"bool","id":31},"have_nanruxiru":{"type":"bool","id":32},"jingsuanyuandian":{"type":"uint32","id":33},"shunweima_2":{"type":"int32","id":34},"shunweima_3":{"type":"int32","id":35},"shunweima_4":{"type":"int32","id":36},"bianjietishi":{"type":"bool","id":37},"ai_level":{"type":"uint32","id":38},"have_zimosun":{"type":"bool","id":39},"disable_multi_yukaman":{"type":"bool","id":40},"guyi_mode":{"type":"uint32","id":41},"disable_leijiyiman":{"type":"bool","id":42}}},"ContestDetailRuleV2":{"fields":{"game_rule":{"type":"ContestDetailRule","id":1},"extra_rule":{"type":"ExtraRule","id":2}},"nested":{"ExtraRule":{"fields":{"required_level":{"type":"uint32","id":1},"max_game_count":{"type":"uint32","id":2}}}}},"GameRuleSetting":{"fields":{"round_type":{"type":"uint32","id":1},"shiduan":{"type":"bool","id":2},"dora_count":{"type":"uint32","id":3},"thinking_type":{"type":"uint32","id":4},"use_detail_rule":{"type":"bool","id":5},"detail_rule_v2":{"type":"ContestDetailRuleV2","id":6}}},"RecordTingPaiInfo":{"fields":{"tile":{"type":"string","id":1},"haveyi":{"type":"bool","id":2},"yiman":{"type":"bool","id":3},"count":{"type":"uint32","id":4},"fu":{"type":"uint32","id":5},"biao_dora_count":{"type":"uint32","id":6},"yiman_zimo":{"type":"bool","id":7},"count_zimo":{"type":"uint32","id":8},"fu_zimo":{"type":"uint32","id":9}}},"RecordNoTilePlayerInfo":{"fields":{"tingpai":{"type":"bool","id":3},"hand":{"rule":"repeated","type":"string","id":4},"tings":{"rule":"repeated","type":"RecordTingPaiInfo","id":5},"liuman":{"type":"bool","id":6}}},"RecordHuleInfo":{"fields":{"hand":{"rule":"repeated","type":"string","id":1},"ming":{"rule":"repeated","type":"string","id":2},"hu_tile":{"type":"string","id":3},"seat":{"type":"uint32","id":4},"zimo":{"type":"bool","id":5},"qinjia":{"type":"bool","id":6},"liqi":{"type":"bool","id":7},"doras":{"rule":"repeated","type":"string","id":8},"li_doras":{"rule":"repeated","type":"string","id":9},"yiman":{"type":"bool","id":10},"count":{"type":"uint32","id":11},"fans":{"rule":"repeated","type":"RecordFanInfo","id":12},"fu":{"type":"uint32","id":13},"point_zimo_qin":{"type":"uint32","id":14},"point_zimo_xian":{"type":"uint32","id":15},"title_id":{"type":"uint32","id":16},"point_sum":{"type":"uint32","id":17},"dadian":{"type":"uint32","id":18},"is_jue_zhang":{"type":"bool","id":19},"xun":{"type":"uint32","id":20},"ting_type":{"type":"uint32","id":21}},"nested":{"RecordFanInfo":{"fields":{"val":{"type":"uint32","id":1},"id":{"type":"uint32","id":2}}}}},"RecordHulesInfo":{"fields":{"seat":{"type":"int32","id":1},"hules":{"rule":"repeated","type":"RecordHuleInfo","id":2}}},"RecordLiujuInfo":{"fields":{"seat":{"type":"uint32","id":1},"type":{"type":"uint32","id":2}}},"RecordNoTileInfo":{"fields":{"liujumanguan":{"type":"bool","id":1},"players":{"rule":"repeated","type":"RecordNoTilePlayerInfo","id":2}}},"RecordLiqiInfo":{"fields":{"seat":{"type":"uint32","id":1},"score":{"type":"uint32","id":2},"is_w":{"type":"bool","id":3},"is_zhen_ting":{"type":"bool","id":4},"xun":{"type":"uint32","id":5},"is_success":{"type":"bool","id":6}}},"RecordGangInfo":{"fields":{"seat":{"type":"uint32","id":1},"type":{"type":"uint32","id":2},"pai":{"type":"string","id":3},"is_dora":{"type":"bool","id":4},"xun":{"type":"uint32","id":5}}},"RecordBaBeiInfo":{"fields":{"seat":{"type":"uint32","id":1},"is_zi_mo":{"type":"bool","id":2},"is_chong":{"type":"bool","id":3},"is_bei":{"type":"bool","id":4}}},"RecordPeiPaiInfo":{"fields":{"dora_count":{"type":"uint32","id":1},"r_dora_count":{"type":"uint32","id":2},"bei_count":{"type":"uint32","id":3}}},"RecordRoundInfo":{"fields":{"name":{"type":"string","id":1},"chang":{"type":"uint32","id":2},"ju":{"type":"uint32","id":3},"ben":{"type":"uint32","id":4},"scores":{"rule":"repeated","type":"uint32","id":5},"liqi_infos":{"rule":"repeated","type":"RecordLiqiInfo","id":7},"gang_infos":{"rule":"repeated","type":"RecordGangInfo","id":8},"peipai_infos":{"rule":"repeated","type":"RecordPeiPaiInfo","id":9},"babai_infos":{"rule":"repeated","type":"RecordBaBeiInfo","id":10},"hules_info":{"type":"RecordHulesInfo","id":11},"liuju_info":{"type":"RecordLiujuInfo","id":12},"no_tile_info":{"type":"RecordNoTileInfo","id":13}}},"RecordAnalysisedData":{"fields":{"round_infos":{"rule":"repeated","type":"RecordRoundInfo","id":1}}},"NotifyCaptcha":{"fields":{"check_id":{"type":"uint32","id":1},"start_time":{"type":"uint32","id":2},"random_str":{"type":"string","id":3},"type":{"type":"uint32","id":4}}},"NotifyRoomGameStart":{"fields":{"game_url":{"type":"string","id":1},"connect_token":{"type":"string","id":2},"game_uuid":{"type":"string","id":3},"location":{"type":"string","id":4}}},"NotifyMatchGameStart":{"fields":{"game_url":{"type":"string","id":1},"connect_token":{"type":"string","id":2},"game_uuid":{"type":"string","id":3},"match_mode_id":{"type":"uint32","id":4},"location":{"type":"string","id":5}}},"NotifyRoomPlayerReady":{"fields":{"account_id":{"type":"uint32","id":1},"ready":{"type":"bool","id":2},"account_list":{"type":"AccountReadyState","id":3},"seq":{"type":"uint32","id":4}},"nested":{"AccountReadyState":{"fields":{"account_id":{"type":"uint32","id":1},"ready":{"type":"bool","id":2}}}}},"NotifyRoomPlayerDressing":{"fields":{"account_id":{"type":"uint32","id":1},"dressing":{"type":"bool","id":2},"account_list":{"type":"AccountDressingState","id":3},"seq":{"type":"uint32","id":4}},"nested":{"AccountDressingState":{"fields":{"account_id":{"type":"uint32","id":1},"dressing":{"type":"bool","id":2}}}}},"NotifyRoomPlayerUpdate":{"fields":{"update_list":{"rule":"repeated","type":"PlayerBaseView","id":1},"remove_list":{"rule":"repeated","type":"uint32","id":2},"owner_id":{"type":"uint32","id":3},"robot_count":{"type":"uint32","id":4},"player_list":{"rule":"repeated","type":"PlayerBaseView","id":5},"seq":{"type":"uint32","id":6}}},"NotifyRoomKickOut":{"fields":{}},"NotifyFriendStateChange":{"fields":{"target_id":{"type":"uint32","id":1},"active_state":{"type":"AccountActiveState","id":2}}},"NotifyFriendViewChange":{"fields":{"target_id":{"type":"uint32","id":1},"base":{"type":"PlayerBaseView","id":2}}},"NotifyFriendChange":{"fields":{"account_id":{"type":"uint32","id":1},"type":{"type":"uint32","id":2},"friend":{"type":"Friend","id":3}}},"NotifyNewFriendApply":{"fields":{"account_id":{"type":"uint32","id":1},"apply_time":{"type":"uint32","id":2},"removed_id":{"type":"uint32","id":3}}},"NotifyClientMessage":{"fields":{"sender":{"type":"PlayerBaseView","id":1},"type":{"type":"uint32","id":2},"content":{"type":"string","id":3}}},"NotifyAccountUpdate":{"fields":{"update":{"type":"AccountUpdate","id":1}}},"NotifyAnotherLogin":{"fields":{}},"NotifyAccountLogout":{"fields":{}},"NotifyAnnouncementUpdate":{"fields":{"update_list":{"rule":"repeated","type":"AnnouncementUpdate","id":1}},"nested":{"AnnouncementUpdate":{"fields":{"lang":{"type":"string","id":1},"platform":{"type":"string","id":2}}}}},"NotifyNewMail":{"fields":{"mail":{"type":"Mail","id":1}}},"NotifyDeleteMail":{"fields":{"mail_id_list":{"rule":"repeated","type":"uint32","id":1}}},"NotifyReviveCoinUpdate":{"fields":{"has_gained":{"type":"bool","id":1}}},"NotifyDailyTaskUpdate":{"fields":{"progresses":{"rule":"repeated","type":"TaskProgress","id":1},"max_daily_task_count":{"type":"uint32","id":2},"refresh_count":{"type":"uint32","id":3}}},"NotifyActivityTaskUpdate":{"fields":{"progresses":{"rule":"repeated","type":"TaskProgress","id":1}}},"NotifyActivityPeriodTaskUpdate":{"fields":{"progresses":{"rule":"repeated","type":"TaskProgress","id":1}}},"NotifyAccountRandomTaskUpdate":{"fields":{"progresses":{"rule":"repeated","type":"TaskProgress","id":1}}},"NotifyActivitySegmentTaskUpdate":{"fields":{"progresses":{"rule":"repeated","type":"lq.SegmentTaskProgress","id":1}}},"NotifyActivityUpdate":{"fields":{"list":{"rule":"repeated","type":"FeedActivityData","id":1}},"nested":{"FeedActivityData":{"fields":{"activity_id":{"type":"uint32","id":1},"feed_count":{"type":"uint32","id":2},"friend_receive_data":{"type":"CountWithTimeData","id":3},"friend_send_data":{"type":"CountWithTimeData","id":4},"gift_inbox":{"rule":"repeated","type":"GiftBoxData","id":5}},"nested":{"CountWithTimeData":{"fields":{"count":{"type":"uint32","id":1},"last_update_time":{"type":"uint32","id":2}}},"GiftBoxData":{"fields":{"id":{"type":"uint32","id":1},"item_id":{"type":"uint32","id":2},"count":{"type":"uint32","id":3},"from_account_id":{"type":"uint32","id":4},"time":{"type":"uint32","id":5},"received":{"type":"uint32","id":6}}}}}}},"NotifyAccountChallengeTaskUpdate":{"fields":{"progresses":{"rule":"repeated","type":"TaskProgress","id":1},"level":{"type":"uint32","id":2},"refresh_count":{"type":"uint32","id":3},"match_count":{"type":"uint32","id":4},"ticket_id":{"type":"uint32","id":5},"rewarded_season":{"rule":"repeated","type":"uint32","id":6}}},"NotifyNewComment":{"fields":{}},"NotifyRollingNotice":{"fields":{"notice":{"type":"RollingNotice","id":1}}},"NotifyGiftSendRefresh":{"fields":{}},"NotifyShopUpdate":{"fields":{"shop_info":{"type":"ShopInfo","id":1}}},"NotifyVipLevelChange":{"fields":{"gift_limit":{"type":"uint32","id":1},"friend_max_count":{"type":"uint32","id":2},"zhp_free_refresh_limit":{"type":"uint32","id":3},"zhp_cost_refresh_limit":{"type":"uint32","id":4},"buddy_bonus":{"type":"float","id":5},"record_collect_limit":{"type":"uint32","id":6}}},"NotifyServerSetting":{"fields":{"settings":{"type":"ServerSettings","id":1}}},"NotifyPayResult":{"fields":{"pay_result":{"type":"uint32","id":1},"order_id":{"type":"string","id":2},"goods_id":{"type":"uint32","id":3},"new_month_ticket":{"type":"uint32","id":4},"resource_modify":{"rule":"repeated","type":"ResourceModify","id":5}},"nested":{"ResourceModify":{"fields":{"id":{"type":"uint32","id":1},"count":{"type":"uint32","id":2},"final":{"type":"uint32","id":3}}}}},"NotifyCustomContestAccountMsg":{"fields":{"unique_id":{"type":"uint32","id":1},"account_id":{"type":"uint32","id":2},"sender":{"type":"string","id":3},"content":{"type":"string","id":4},"verified":{"type":"uint32","id":5}}},"NotifyCustomContestSystemMsg":{"fields":{"unique_id":{"type":"uint32","id":1},"type":{"type":"uint32","id":2},"uuid":{"type":"string","id":3},"game_start":{"type":"CustomizedContestGameStart","id":4},"game_end":{"type":"CustomizedContestGameEnd","id":5}}},"NotifyMatchTimeout":{"fields":{"sid":{"type":"string","id":1}}},"NotifyCustomContestState":{"fields":{"unique_id":{"type":"uint32","id":1},"state":{"type":"uint32","id":2}}},"NotifyActivityChange":{"fields":{"new_activities":{"rule":"repeated","type":"Activity","id":1},"end_activities":{"rule":"repeated","type":"uint32","id":2}}},"NotifyAFKResult":{"fields":{"type":{"type":"uint32","id":1},"ban_end_time":{"type":"uint32","id":2},"game_uuid":{"type":"string","id":3}}},"NotifyGameFinishRewardV2":{"fields":{"mode_id":{"type":"uint32","id":1},"level_change":{"type":"LevelChange","id":2},"match_chest":{"type":"MatchChest","id":3},"main_character":{"type":"MainCharacter","id":4},"character_gift":{"type":"CharacterGift","id":5}},"nested":{"LevelChange":{"fields":{"origin":{"type":"AccountLevel","id":1},"final":{"type":"AccountLevel","id":2},"type":{"type":"uint32","id":3}}},"MatchChest":{"fields":{"chest_id":{"type":"uint32","id":1},"origin":{"type":"uint32","id":2},"final":{"type":"uint32","id":3},"is_graded":{"type":"bool","id":4},"rewards":{"rule":"repeated","type":"RewardSlot","id":5}}},"MainCharacter":{"fields":{"level":{"type":"uint32","id":1},"exp":{"type":"uint32","id":2},"add":{"type":"uint32","id":3}}},"CharacterGift":{"fields":{"origin":{"type":"uint32","id":1},"final":{"type":"uint32","id":2},"add":{"type":"uint32","id":3},"is_graded":{"type":"bool","id":4}}}}},"NotifyActivityRewardV2":{"fields":{"activity_reward":{"rule":"repeated","type":"ActivityReward","id":1}},"nested":{"ActivityReward":{"fields":{"activity_id":{"type":"uint32","id":1},"rewards":{"rule":"repeated","type":"RewardSlot","id":2}}}}},"NotifyActivityPointV2":{"fields":{"activity_points":{"rule":"repeated","type":"ActivityPoint","id":1}},"nested":{"ActivityPoint":{"fields":{"activity_id":{"type":"uint32","id":1},"point":{"type":"uint32","id":2}}}}},"NotifyLeaderboardPointV2":{"fields":{"leaderboard_points":{"rule":"repeated","type":"LeaderboardPoint","id":1}},"nested":{"LeaderboardPoint":{"fields":{"leaderboard_id":{"type":"uint32","id":1},"point":{"type":"uint32","id":2}}}}}}}}} 2 | -------------------------------------------------------------------------------- /ms_tournament/ms-admin-plugin.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | import re 3 | import sys 4 | 5 | from google.protobuf.compiler import plugin_pb2 as plugin 6 | 7 | header = '''# -*- coding: utf-8 -*- 8 | # Generated. DO NOT EDIT! 9 | 10 | import ms_tournament.protocol_admin_pb2 as pb 11 | from ms_tournament.base import MSRPCService 12 | ''' 13 | 14 | cls_tplt = ''' 15 | class {class_name}(MSRPCService): 16 | version = None 17 | 18 | _req = {{ 19 | {req_list} 20 | }} 21 | _res = {{ 22 | {res_list} 23 | }} 24 | 25 | def get_package_name(self): 26 | return '{package_name}' 27 | 28 | def get_service_name(self): 29 | return '{class_name}' 30 | 31 | def get_req_class(self, method): 32 | return {class_name}._req[method] 33 | 34 | def get_res_class(self, method): 35 | return {class_name}._res[method] 36 | {func_list} 37 | ''' 38 | 39 | dict_template = ' \'{method_name}\': pb.{type_name},' 40 | 41 | func_template = ''' 42 | async def {func_name}(self, req): 43 | return await self.call_method('{method_name}', req)''' 44 | 45 | 46 | def to_snake_case(name): 47 | s1 = re.sub('(.)([A-Z][a-z]+)', r'\1_\2', name) 48 | return re.sub('([a-z0-9])([A-Z])', r'\1_\2', s1).lower() 49 | 50 | 51 | def generate_code(request, response): 52 | for proto_file in request.proto_file: 53 | package_name = proto_file.package 54 | 55 | services = [] 56 | for srv in proto_file.service: 57 | class_name = srv.name 58 | req_list = [] 59 | res_list = [] 60 | func_list = [] 61 | for mtd in srv.method: 62 | method_name = mtd.name 63 | func_name = to_snake_case(method_name) 64 | 65 | req_name = mtd.input_type.rsplit('.', 1)[-1] 66 | res_name = mtd.output_type.rsplit('.', 1)[-1] 67 | req_list.append(dict_template.format(method_name=method_name, type_name=req_name)) 68 | res_list.append(dict_template.format(method_name=method_name, type_name=res_name)) 69 | func_list.append(func_template.format(method_name=method_name, func_name=func_name)) 70 | 71 | cls = cls_tplt.format(package_name=package_name, 72 | class_name=class_name, 73 | req_list='\n'.join(req_list), 74 | res_list='\n'.join(res_list), 75 | func_list='\n'.join(func_list)) 76 | services.append(cls) 77 | 78 | body = '\n'.join(services) 79 | src = header + '\n' + body 80 | f = response.file.add() 81 | f.name = 'rpc.py' 82 | f.content = src 83 | 84 | 85 | if __name__ == '__main__': 86 | # Read request message from stdin 87 | data = sys.stdin.buffer.read() 88 | 89 | # Parse request 90 | request = plugin.CodeGeneratorRequest() 91 | request.ParseFromString(data) 92 | 93 | # Create response 94 | response = plugin.CodeGeneratorResponse() 95 | 96 | # Generate code 97 | generate_code(request, response) 98 | 99 | # Serialise response message 100 | output = response.SerializeToString() 101 | 102 | # Write to stdout 103 | sys.stdout.buffer.write(output) 104 | -------------------------------------------------------------------------------- /ms_tournament/protocol_admin.proto: -------------------------------------------------------------------------------- 1 | syntax = "proto3"; 2 | 3 | package lq; 4 | 5 | service CustomizedContestManagerApi { 6 | rpc loginContestManager (ReqContestManageLogin) returns (ResContestManageLogin); 7 | rpc oauth2AuthContestManager (ReqContestManageOauth2Auth) returns (ResContestManageOauth2Auth); 8 | rpc oauth2LoginContestManager (ReqContestManageOauth2Login) returns (ResContestManageOauth2Login); 9 | rpc logoutContestManager (ReqCommon) returns (ResCommon); 10 | rpc fetchRelatedContestList (ReqCommon) returns (ResFetchRelatedContestList); 11 | rpc createContest (ReqCreateCustomizedContest) returns (ResCreateCustomizedContest); 12 | rpc deleteContest (ReqDeleteCustomizedContest) returns (ResCommon); 13 | rpc prolongContest (ReqProlongContest) returns (ResProlongContest); 14 | rpc manageContest (ReqManageContest) returns (ResManageContest); 15 | rpc fetchContestInfo (ReqCommon) returns (ResManageContest); 16 | rpc exitManageContest (ReqCommon) returns (ResCommon); 17 | rpc fetchContestGameRule (ReqCommon) returns (ResFetchContestGameRule); 18 | rpc updateContestGameRule (ReqUpdateContestGameRule) returns (ResCommon); 19 | rpc searchAccountByNickname (ReqSearchAccountByNickname) returns (ResSearchAccountByNickname); 20 | rpc searchAccountByEid (ReqSearchAccountByEid) returns (ResSearchAccountByEid); 21 | rpc fetchContestPlayer (ReqCommon) returns (ResFetchCustomizedContestPlayer); 22 | rpc updateContestPlayer (ReqUpdateCustomizedContestPlayer) returns (ResCommon); 23 | rpc startManageGame (ReqCommon) returns (ResStartManageGame); 24 | rpc stopManageGame (ReqCommon) returns (ResCommon); 25 | rpc lockGamePlayer (ReqLockGamePlayer) returns (ResCommon); 26 | rpc unlockGamePlayer (ReqUnlockGamePlayer) returns (ResCommon); 27 | rpc createContestGame (ReqCreateContestGame) returns (ResCreateContestGame); 28 | rpc fetchContestGameRecords (ReqFetchCustomizedContestGameRecordList) returns (ResFetchCustomizedContestGameRecordList); 29 | rpc removeContestGameRecord (ReqRemoveContestGameRecord) returns (ResCommon); 30 | rpc fetchContestNotice (ReqFetchContestNotice) returns (ResFetchContestNotice); 31 | rpc updateContestNotice (ReqUpdateCustomizedContestNotice) returns (ResCommon); 32 | rpc fetchContestManager (ReqCommon) returns (ResFetchCustomizedContestManager); 33 | rpc updateContestManager (ReqUpdateCustomizedContestManager) returns (ResCommon); 34 | rpc fetchChatSetting (ReqCommon) returns (ResCustomizedContestChatInfo); 35 | rpc updateChatSetting (ReqUpdateCustomizedContestChatSetting) returns (ResUpdateCustomizedContestChatSetting); 36 | rpc updateGameTag (ReqUpdateGameTag) returns (ResCommon); 37 | rpc terminateGame (ReqTerminateContestGame) returns (ResCommon); 38 | rpc pauseGame (ReqPauseContestGame) returns (ResCommon); 39 | rpc resumeGame (ReqResumeContestGame) returns (ResCommon); 40 | rpc fetchCurrentRankList (ReqCommon) returns (ResFetchCurrentRankList); 41 | rpc fetchContestLastModify (ReqCommon) returns (ResFetchContestLastModify); 42 | rpc fetchContestObserver (ReqCommon) returns (ResFetchContestObserver); 43 | rpc addContestObserver (ReqAddContestObserver) returns (ResAddContestObserver); 44 | rpc removeContestObserver (ReqRemoveContestObserver) returns (ResCommon); 45 | rpc fetchContestChatHistory (ReqCommon) returns (ResFetchContestChatHistory); 46 | rpc clearChatHistory (ReqClearChatHistory) returns (ResCommon); 47 | } 48 | 49 | message CustomizedContest { 50 | uint32 unique_id = 1; 51 | uint32 creator_id = 2; 52 | uint32 contest_id = 3; 53 | string contest_name = 4; 54 | uint32 state = 5; 55 | uint32 create_time = 6; 56 | uint32 start_time = 7; 57 | uint32 finish_time = 8; 58 | bool open = 9; 59 | uint32 rank_rule = 10; 60 | uint32 deadline = 11; 61 | bool auto_match = 12; 62 | bool auto_disable_end_chat = 13; 63 | uint32 contest_type = 14; 64 | repeated uint32 hidden_zones = 15; 65 | repeated uint32 banned_zones = 16; 66 | uint32 observer_switch = 17; 67 | uint32 emoji_switch = 18; 68 | uint32 player_roster_type = 19; 69 | } 70 | 71 | message ContestGameInfo { 72 | string game_uuid = 1; 73 | repeated Player players = 2; 74 | uint32 start_time = 3; 75 | uint32 end_time = 4; 76 | message Player { 77 | uint32 account_id = 1; 78 | string nickname = 2; 79 | } 80 | 81 | } 82 | 83 | message ContestPlayerInfo { 84 | uint32 account_id = 1; 85 | string nickname = 2; 86 | } 87 | 88 | message ContestMatchingPlayer { 89 | uint32 account_id = 1; 90 | string nickname = 2; 91 | Controller controller = 3; 92 | message Controller { 93 | uint32 account_id = 1; 94 | string nickname = 2; 95 | } 96 | 97 | } 98 | 99 | message ReqContestManageLogin { 100 | string account = 1; 101 | string password = 2; 102 | bool gen_access_token = 3; 103 | uint32 type = 4; 104 | } 105 | 106 | message ResContestManageLogin { 107 | Error error = 1; 108 | uint32 account_id = 2; 109 | string nickname = 3; 110 | string access_token = 4; 111 | uint32 diamond = 5; 112 | uint32 last_create_time = 6; 113 | } 114 | 115 | message ReqContestManageOauth2Auth { 116 | uint32 type = 1; 117 | string code = 2; 118 | string uid = 3; 119 | } 120 | 121 | message ResContestManageOauth2Auth { 122 | Error error = 1; 123 | string access_token = 2; 124 | } 125 | 126 | message ReqContestManageOauth2Login { 127 | uint32 type = 1; 128 | string access_token = 2; 129 | bool reconnect = 3; 130 | } 131 | 132 | message ResContestManageOauth2Login { 133 | Error error = 1; 134 | uint32 account_id = 2; 135 | string nickname = 3; 136 | string access_token = 4; 137 | uint32 diamond = 5; 138 | uint32 last_create_time = 6; 139 | } 140 | 141 | message ResFetchRelatedContestList { 142 | Error error = 1; 143 | repeated CustomizedContest contests = 2; 144 | } 145 | 146 | message ReqCreateCustomizedContest { 147 | string contest_name = 1; 148 | uint32 start_time = 2; 149 | uint32 finish_time = 3; 150 | bool open = 4; 151 | uint32 rank_rule = 5; 152 | GameRuleSetting game_rule_setting = 6; 153 | } 154 | 155 | message ResCreateCustomizedContest { 156 | Error error = 1; 157 | CustomizedContest contest = 2; 158 | uint32 diamond = 3; 159 | } 160 | 161 | message ReqDeleteCustomizedContest { 162 | uint32 unique_id = 1; 163 | } 164 | 165 | message ReqProlongContest { 166 | uint32 unique_id = 1; 167 | } 168 | 169 | message ResProlongContest { 170 | Error error = 1; 171 | uint32 deadline = 2; 172 | } 173 | 174 | message ReqManageContest { 175 | uint32 unique_id = 1; 176 | } 177 | 178 | message ResManageContest { 179 | Error error = 1; 180 | CustomizedContest contest = 2; 181 | } 182 | 183 | message ResFetchContestGameRule { 184 | Error error = 1; 185 | GameRuleSetting game_rule_setting = 2; 186 | } 187 | 188 | message ReqUpdateContestGameRule { 189 | string contest_name = 1; 190 | uint32 start_time = 2; 191 | uint32 finish_time = 3; 192 | bool open = 4; 193 | uint32 rank_rule = 5; 194 | GameRuleSetting game_rule_setting = 6; 195 | bool auto_match = 7; 196 | bool auto_disable_end_chat = 8; 197 | uint32 contest_type = 9; 198 | string banned_zones = 10; 199 | string hidden_zones = 11; 200 | bool emoji_switch = 12; 201 | uint32 player_roster_type = 13; 202 | } 203 | 204 | message ReqSearchAccountByNickname { 205 | repeated string query_nicknames = 1; 206 | } 207 | 208 | message ResSearchAccountByNickname { 209 | Error error = 1; 210 | repeated Item search_result = 3; 211 | message Item { 212 | uint32 account_id = 1; 213 | string nickname = 2; 214 | } 215 | 216 | } 217 | 218 | message ReqSearchAccountByEid { 219 | repeated uint32 eids = 1; 220 | } 221 | 222 | message ResSearchAccountByEid { 223 | Error error = 1; 224 | repeated Item search_result = 3; 225 | message Item { 226 | uint32 account_id = 1; 227 | string nickname = 2; 228 | } 229 | 230 | } 231 | 232 | message ResFetchCustomizedContestPlayer { 233 | Error error = 1; 234 | repeated ContestPlayerInfo players = 2; 235 | } 236 | 237 | message ReqUpdateCustomizedContestPlayer { 238 | uint32 setting_type = 1; 239 | repeated string nicknames = 2; 240 | repeated uint32 account_ids = 3; 241 | } 242 | 243 | message ResUpdateCustomizedContestPlayer { 244 | Error error = 1; 245 | repeated uint32 failed_index = 2; 246 | } 247 | 248 | message ResStartManageGame { 249 | Error error = 1; 250 | repeated ContestMatchingPlayer players = 2; 251 | repeated ContestGameInfo games = 3; 252 | } 253 | 254 | message ReqLockGamePlayer { 255 | uint32 account_id = 1; 256 | } 257 | 258 | message ReqUnlockGamePlayer { 259 | uint32 account_id = 1; 260 | } 261 | 262 | message ReqCreateContestGame { 263 | repeated Slot slots = 1; 264 | string tag = 2; 265 | bool random_position = 3; 266 | bool open_live = 4; 267 | bool chat_broadcast_for_end = 5; 268 | uint32 ai_level = 6; 269 | message Slot { 270 | uint32 account_id = 1; 271 | uint32 start_point = 2; 272 | uint32 seat = 3; 273 | } 274 | 275 | } 276 | 277 | message ResCreateContestGame { 278 | Error error = 1; 279 | string game_uuid = 2; 280 | } 281 | 282 | message ReqFetchCustomizedContestGameRecordList { 283 | uint32 last_index = 2; 284 | } 285 | 286 | message ResFetchCustomizedContestGameRecordList { 287 | Error error = 1; 288 | uint32 next_index = 2; 289 | repeated Item record_list = 3; 290 | message Item { 291 | RecordGame record = 1; 292 | string tag = 2; 293 | } 294 | 295 | } 296 | 297 | message ReqRemoveContestGameRecord { 298 | string uuid = 1; 299 | } 300 | 301 | message ReqFetchContestNotice { 302 | repeated uint32 notice_types = 1; 303 | } 304 | 305 | message ResFetchContestNotice { 306 | Error error = 1; 307 | repeated string notices = 2; 308 | } 309 | 310 | message ReqUpdateCustomizedContestNotice { 311 | uint32 notice_type = 1; 312 | string content = 2; 313 | } 314 | 315 | message ResFetchCustomizedContestManager { 316 | Error error = 1; 317 | repeated ContestPlayerInfo players = 2; 318 | } 319 | 320 | message ReqUpdateCustomizedContestManager { 321 | uint32 setting_type = 1; 322 | repeated string nicknames = 2; 323 | repeated uint32 account_ids = 3; 324 | } 325 | 326 | message ResCustomizedContestChatInfo { 327 | Error error = 1; 328 | uint32 chat_limit_type = 2; 329 | repeated Item chat_limit_roster = 3; 330 | message Item { 331 | uint32 account_id = 1; 332 | string nickname = 2; 333 | } 334 | 335 | } 336 | 337 | message ReqUpdateCustomizedContestChatSetting { 338 | uint32 setting_type = 1; 339 | repeated string nicknames = 2; 340 | repeated uint32 account_ids = 3; 341 | uint32 chat_limit_type = 4; 342 | } 343 | 344 | message ResUpdateCustomizedContestChatSetting { 345 | Error error = 1; 346 | repeated uint32 failed_index = 2; 347 | } 348 | 349 | message ReqUpdateGameTag { 350 | string uuid = 1; 351 | string tag = 2; 352 | } 353 | 354 | message ReqTerminateContestGame { 355 | string uuid = 1; 356 | } 357 | 358 | message ReqPauseContestGame { 359 | string uuid = 1; 360 | } 361 | 362 | message ReqResumeContestGame { 363 | string uuid = 1; 364 | } 365 | 366 | message ResFetchCurrentRankList { 367 | Error error = 1; 368 | repeated AccountRankData rank_list = 2; 369 | uint32 rank_rule = 3; 370 | message AccountRankData { 371 | uint32 account_id = 1; 372 | string nickname = 2; 373 | int32 total_point = 3; 374 | uint32 total_count = 4; 375 | } 376 | 377 | } 378 | 379 | message ResFetchContestLastModify { 380 | ContestLastModify modify = 1; 381 | message ContestLastModify { 382 | string contest_name = 1; 383 | string external_notice = 2; 384 | string internal_notice = 3; 385 | string manager_notice = 4; 386 | string reason = 5; 387 | uint32 status = 6; 388 | } 389 | 390 | } 391 | 392 | message ResFetchContestObserver { 393 | Error error = 1; 394 | repeated Observer observers = 2; 395 | message Observer { 396 | uint32 account_id = 1; 397 | string nickname = 2; 398 | } 399 | 400 | } 401 | 402 | message ReqAddContestObserver { 403 | repeated Observer observers = 1; 404 | message Observer { 405 | uint32 account_id = 1; 406 | string nickname = 2; 407 | } 408 | 409 | } 410 | 411 | message ResAddContestObserver { 412 | Error error = 1; 413 | repeated Observer success = 2; 414 | message Observer { 415 | uint32 account_id = 1; 416 | string nickname = 2; 417 | } 418 | 419 | } 420 | 421 | message ReqRemoveContestObserver { 422 | repeated uint32 observers = 1; 423 | } 424 | 425 | message ResFetchContestChatHistory { 426 | Error error = 1; 427 | repeated bytes chat_history = 2; 428 | } 429 | 430 | message ReqClearChatHistory { 431 | uint32 unique_id = 1; 432 | } 433 | 434 | message NotifyContestMatchingPlayer { 435 | uint32 unique_id = 1; 436 | uint32 type = 2; 437 | uint32 account_id = 3; 438 | string nickname = 4; 439 | } 440 | 441 | message NotifyContestMatchingPlayerLock { 442 | uint32 unique_id = 1; 443 | uint32 type = 2; 444 | uint32 account_id = 3; 445 | uint32 manager_id = 4; 446 | } 447 | 448 | message NotifyContestGameStart { 449 | uint32 unique_id = 1; 450 | ContestGameInfo game_info = 2; 451 | } 452 | 453 | message NotifyContestGameEnd { 454 | uint32 unique_id = 1; 455 | string game_uuid = 2; 456 | } 457 | 458 | message NotifyContestNoticeUpdate { 459 | uint32 unique_id = 1; 460 | uint32 notice_type = 2; 461 | string content = 3; 462 | } 463 | 464 | message NotifyContestManagerKick { 465 | uint32 reason = 1; 466 | } 467 | 468 | message Error { 469 | uint32 code = 1; 470 | repeated uint32 u32_params = 2; 471 | repeated string str_params = 3; 472 | string json_param = 4; 473 | } 474 | 475 | message Wrapper { 476 | string name = 1; 477 | bytes data = 2; 478 | } 479 | 480 | message NetworkEndpoint { 481 | string family = 1; 482 | string address = 2; 483 | uint32 port = 3; 484 | } 485 | 486 | message ReqCommon { 487 | } 488 | 489 | message ResCommon { 490 | Error error = 1; 491 | } 492 | 493 | message ResAccountUpdate { 494 | Error error = 1; 495 | AccountUpdate update = 2; 496 | } 497 | 498 | message AntiAddiction { 499 | uint32 online_duration = 1; 500 | } 501 | 502 | message AccountMahjongStatistic { 503 | repeated uint32 final_position_counts = 1; 504 | RoundSummary recent_round = 2; 505 | HuSummary recent_hu = 3; 506 | HighestHuRecord highest_hu = 4; 507 | Liqi20Summary recent_20_hu_summary = 6; 508 | LiQi10Summary recent_10_hu_summary = 7; 509 | repeated GameResult recent_10_game_result = 8; 510 | message RoundSummary { 511 | uint32 total_count = 1; 512 | uint32 rong_count = 2; 513 | uint32 zimo_count = 3; 514 | uint32 fangchong_count = 4; 515 | } 516 | 517 | message HuSummary { 518 | uint32 total_count = 1; 519 | uint32 dora_round_count = 2; 520 | uint32 total_fan = 3; 521 | } 522 | 523 | message HighestHuRecord { 524 | uint32 fanshu = 1; 525 | uint32 doranum = 2; 526 | string title = 3; 527 | repeated string hands = 4; 528 | repeated string ming = 5; 529 | string hupai = 6; 530 | uint32 title_id = 7; 531 | } 532 | 533 | message Liqi20Summary { 534 | uint32 total_count = 1; 535 | uint32 total_lidora_count = 2; 536 | uint32 average_hu_point = 3; 537 | } 538 | 539 | message LiQi10Summary { 540 | uint32 total_xuanshang = 1; 541 | uint32 total_fanshu = 2; 542 | } 543 | 544 | message GameResult { 545 | uint32 rank = 1; 546 | int32 final_point = 2; 547 | } 548 | 549 | } 550 | 551 | message AccountStatisticData { 552 | uint32 mahjong_category = 1; 553 | uint32 game_category = 2; 554 | AccountMahjongStatistic statistic = 3; 555 | uint32 game_type = 4; 556 | } 557 | 558 | message AccountLevel { 559 | uint32 id = 1; 560 | uint32 score = 2; 561 | } 562 | 563 | message ViewSlot { 564 | uint32 slot = 1; 565 | uint32 item_id = 2; 566 | } 567 | 568 | message Account { 569 | uint32 account_id = 1; 570 | string nickname = 2; 571 | uint32 login_time = 3; 572 | uint32 logout_time = 4; 573 | uint32 room_id = 5; 574 | AntiAddiction anti_addiction = 6; 575 | uint32 title = 7; 576 | string signature = 8; 577 | string email = 9; 578 | uint32 email_verify = 10; 579 | uint32 gold = 11; 580 | uint32 diamond = 12; 581 | uint32 avatar_id = 13; 582 | uint32 vip = 14; 583 | int32 birthday = 15; 584 | string phone = 16; 585 | uint32 phone_verify = 17; 586 | repeated PlatformDiamond platform_diamond = 18; 587 | AccountLevel level = 21; 588 | AccountLevel level3 = 22; 589 | uint32 avatar_frame = 23; 590 | uint32 skin_ticket = 24; 591 | repeated PlatformSkinTicket platform_skin_ticket = 25; 592 | uint32 verified = 26; 593 | repeated ChallengeLevel challenge_levels = 27; 594 | repeated AchievementCount achievement_count = 28; 595 | uint32 frozen_state = 29; 596 | message PlatformDiamond { 597 | uint32 id = 1; 598 | uint32 count = 2; 599 | } 600 | 601 | message PlatformSkinTicket { 602 | uint32 id = 1; 603 | uint32 count = 2; 604 | } 605 | 606 | message ChallengeLevel { 607 | uint32 season = 1; 608 | uint32 level = 2; 609 | uint32 rank = 3; 610 | } 611 | 612 | message AchievementCount { 613 | uint32 rare = 1; 614 | uint32 count = 2; 615 | } 616 | 617 | } 618 | 619 | message AccountOwnerData { 620 | repeated uint32 unlock_characters = 1; 621 | } 622 | 623 | message AccountUpdate { 624 | repeated NumericalUpdate numerical = 1; 625 | CharacterUpdate character = 2; 626 | BagUpdate bag = 3; 627 | AchievementUpdate achievement = 4; 628 | AccountShiLian shilian = 5; 629 | DailyTaskUpdate daily_task = 6; 630 | TitleUpdate title = 7; 631 | repeated uint32 new_recharged_list = 8; 632 | TaskUpdate activity_task = 9; 633 | TaskUpdate activity_flip_task = 10; 634 | TaskUpdate activity_period_task = 11; 635 | TaskUpdate activity_random_task = 12; 636 | AccountChallengeUpdate challenge = 13; 637 | AccountABMatchUpdate ab_match = 14; 638 | lq.AccountActivityUpdate activity = 15; 639 | SegmentTaskUpdate activity_segment_task = 16; 640 | message NumericalUpdate { 641 | uint32 id = 1; 642 | uint32 final = 3; 643 | } 644 | 645 | message CharacterUpdate { 646 | repeated Character characters = 2; 647 | repeated uint32 skins = 3; 648 | repeated uint32 finished_endings = 4; 649 | repeated uint32 rewarded_endings = 5; 650 | } 651 | 652 | message AchievementUpdate { 653 | repeated AchievementProgress progresses = 1; 654 | repeated uint32 rewarded_group = 2; 655 | } 656 | 657 | message DailyTaskUpdate { 658 | repeated TaskProgress progresses = 1; 659 | repeated uint32 task_list = 2; 660 | } 661 | 662 | message TitleUpdate { 663 | repeated uint32 new_titles = 1; 664 | repeated uint32 remove_titles = 2; 665 | } 666 | 667 | message TaskUpdate { 668 | repeated TaskProgress progresses = 1; 669 | repeated uint32 task_list = 2; 670 | } 671 | 672 | message AccountChallengeUpdate { 673 | repeated TaskProgress progresses = 1; 674 | uint32 level = 2; 675 | uint32 refresh_count = 3; 676 | uint32 match_count = 4; 677 | uint32 ticket_id = 5; 678 | repeated uint32 task_list = 6; 679 | repeated uint32 rewarded_season = 7; 680 | } 681 | 682 | message AccountABMatchUpdate { 683 | uint32 match_id = 1; 684 | uint32 match_count = 2; 685 | uint32 buy_in_count = 3; 686 | uint32 point = 4; 687 | bool rewarded = 5; 688 | repeated MatchPoint match_max_point = 6; 689 | bool quit = 7; 690 | message MatchPoint { 691 | uint32 match_id = 1; 692 | uint32 point = 2; 693 | } 694 | 695 | } 696 | 697 | message SegmentTaskUpdate { 698 | repeated lq.SegmentTaskProgress progresses = 1; 699 | repeated uint32 task_list = 2; 700 | } 701 | 702 | } 703 | 704 | message GameMetaData { 705 | uint32 room_id = 1; 706 | uint32 mode_id = 2; 707 | uint32 contest_uid = 3; 708 | } 709 | 710 | message AccountPlayingGame { 711 | string game_uuid = 1; 712 | uint32 category = 2; 713 | GameMetaData meta = 3; 714 | } 715 | 716 | message AccountCacheView { 717 | uint32 cache_version = 1; 718 | uint32 account_id = 2; 719 | string nickname = 3; 720 | uint32 login_time = 4; 721 | uint32 logout_time = 5; 722 | bool is_online = 6; 723 | uint32 room_id = 7; 724 | uint32 title = 8; 725 | uint32 avatar_id = 9; 726 | uint32 vip = 10; 727 | AccountLevel level = 11; 728 | AccountPlayingGame playing_game = 12; 729 | AccountLevel level3 = 13; 730 | uint32 avatar_frame = 14; 731 | uint32 verified = 15; 732 | uint32 ban_deadline = 16; 733 | uint32 comment_ban = 17; 734 | uint32 ban_state = 18; 735 | } 736 | 737 | message PlayerBaseView { 738 | uint32 account_id = 1; 739 | uint32 avatar_id = 2; 740 | uint32 title = 3; 741 | string nickname = 4; 742 | AccountLevel level = 5; 743 | AccountLevel level3 = 6; 744 | uint32 avatar_frame = 7; 745 | uint32 verified = 8; 746 | uint32 is_banned = 9; 747 | } 748 | 749 | message PlayerGameView { 750 | uint32 account_id = 1; 751 | uint32 avatar_id = 2; 752 | uint32 title = 3; 753 | string nickname = 4; 754 | AccountLevel level = 5; 755 | Character character = 6; 756 | AccountLevel level3 = 7; 757 | uint32 avatar_frame = 8; 758 | uint32 verified = 9; 759 | repeated ViewSlot views = 10; 760 | } 761 | 762 | message GameSetting { 763 | uint32 emoji_switch = 1; 764 | } 765 | 766 | message GameMode { 767 | uint32 mode = 1; 768 | bool ai = 4; 769 | string extendinfo = 5; 770 | GameDetailRule detail_rule = 6; 771 | GameTestingEnvironmentSet testing_environment = 7; 772 | GameSetting game_setting = 8; 773 | } 774 | 775 | message GameTestingEnvironmentSet { 776 | uint32 paixing = 1; 777 | uint32 left_count = 2; 778 | } 779 | 780 | message GameDetailRule { 781 | uint32 time_fixed = 1; 782 | uint32 time_add = 2; 783 | uint32 dora_count = 3; 784 | uint32 shiduan = 4; 785 | uint32 init_point = 5; 786 | uint32 fandian = 6; 787 | bool can_jifei = 7; 788 | uint32 tianbian_value = 8; 789 | uint32 liqibang_value = 9; 790 | uint32 changbang_value = 10; 791 | uint32 noting_fafu_1 = 11; 792 | uint32 noting_fafu_2 = 12; 793 | uint32 noting_fafu_3 = 13; 794 | bool have_liujumanguan = 14; 795 | bool have_qieshangmanguan = 15; 796 | bool have_biao_dora = 16; 797 | bool have_gang_biao_dora = 17; 798 | bool ming_dora_immediately_open = 18; 799 | bool have_li_dora = 19; 800 | bool have_gang_li_dora = 20; 801 | bool have_sifenglianda = 21; 802 | bool have_sigangsanle = 22; 803 | bool have_sijializhi = 23; 804 | bool have_jiuzhongjiupai = 24; 805 | bool have_sanjiahele = 25; 806 | bool have_toutiao = 26; 807 | bool have_helelianzhuang = 27; 808 | bool have_helezhongju = 28; 809 | bool have_tingpailianzhuang = 29; 810 | bool have_tingpaizhongju = 30; 811 | bool have_yifa = 31; 812 | bool have_nanruxiru = 32; 813 | uint32 jingsuanyuandian = 33; 814 | int32 shunweima_2 = 34; 815 | int32 shunweima_3 = 35; 816 | int32 shunweima_4 = 36; 817 | bool bianjietishi = 37; 818 | uint32 ai_level = 38; 819 | bool have_zimosun = 39; 820 | bool disable_multi_yukaman = 40; 821 | uint32 fanfu = 41; 822 | uint32 guyi_mode = 42; 823 | uint32 dora3_mode = 43; 824 | uint32 begin_open_mode = 44; 825 | uint32 jiuchao_mode = 45; 826 | uint32 muyu_mode = 46; 827 | uint32 open_hand = 47; 828 | uint32 xuezhandaodi = 48; 829 | uint32 huansanzhang = 49; 830 | uint32 chuanma = 50; 831 | uint32 reveal_discard = 51; 832 | bool disable_leijiyiman = 60; 833 | } 834 | 835 | message Room { 836 | uint32 room_id = 1; 837 | uint32 owner_id = 2; 838 | GameMode mode = 3; 839 | uint32 max_player_count = 4; 840 | repeated PlayerGameView persons = 5; 841 | repeated uint32 ready_list = 6; 842 | bool is_playing = 7; 843 | bool public_live = 8; 844 | uint32 robot_count = 9; 845 | uint32 tournament_id = 10; 846 | uint32 seq = 11; 847 | } 848 | 849 | message GameEndResult { 850 | repeated PlayerItem players = 1; 851 | message PlayerItem { 852 | uint32 seat = 1; 853 | int32 total_point = 2; 854 | int32 part_point_1 = 3; 855 | int32 part_point_2 = 4; 856 | int32 grading_score = 5; 857 | int32 gold = 6; 858 | } 859 | 860 | } 861 | 862 | message GameConnectInfo { 863 | string connect_token = 2; 864 | string game_uuid = 3; 865 | string location = 4; 866 | } 867 | 868 | message ItemGainRecord { 869 | uint32 item_id = 1; 870 | uint32 count = 2; 871 | } 872 | 873 | message ItemGainRecords { 874 | uint32 record_time = 1; 875 | uint32 limit_source_id = 2; 876 | repeated ItemGainRecord records = 3; 877 | } 878 | 879 | message FakeRandomRecords { 880 | uint32 item_id = 1; 881 | uint32 special_item_id = 2; 882 | uint32 gain_count = 3; 883 | repeated uint32 gain_history = 4; 884 | } 885 | 886 | message Item { 887 | uint32 item_id = 1; 888 | uint32 stack = 2; 889 | } 890 | 891 | message Bag { 892 | repeated Item items = 1; 893 | repeated ItemGainRecords daily_gain_record = 2; 894 | } 895 | 896 | message BagUpdate { 897 | repeated Item update_items = 1; 898 | repeated ItemGainRecords update_daily_gain_record = 2; 899 | } 900 | 901 | message RewardSlot { 902 | uint32 id = 1; 903 | uint32 count = 2; 904 | } 905 | 906 | message OpenResult { 907 | RewardSlot reward = 1; 908 | RewardSlot replace = 2; 909 | } 910 | 911 | message RewardPlusResult { 912 | uint32 id = 1; 913 | uint32 count = 2; 914 | Exchange exchange = 3; 915 | message Exchange { 916 | uint32 id = 1; 917 | uint32 count = 2; 918 | uint32 exchange = 3; 919 | } 920 | 921 | } 922 | 923 | message ExecuteReward { 924 | RewardSlot reward = 1; 925 | RewardSlot replace = 2; 926 | uint32 replace_count = 3; 927 | } 928 | 929 | message I18nContext { 930 | string lang = 1; 931 | string context = 2; 932 | } 933 | 934 | message Mail { 935 | uint32 mail_id = 1; 936 | uint32 state = 2; 937 | bool take_attachment = 3; 938 | string title = 4; 939 | string content = 5; 940 | repeated RewardSlot attachments = 6; 941 | uint32 create_time = 7; 942 | uint32 expire_time = 8; 943 | uint32 reference_id = 9; 944 | repeated I18nContext title_i18n = 10; 945 | repeated I18nContext content_i18n = 11; 946 | } 947 | 948 | message AchievementProgress { 949 | uint32 id = 1; 950 | uint32 counter = 2; 951 | bool achieved = 3; 952 | bool rewarded = 4; 953 | uint32 achieved_time = 5; 954 | } 955 | 956 | message AccountStatisticByGameMode { 957 | uint32 mode = 1; 958 | uint32 game_count_sum = 2; 959 | repeated uint32 game_final_position = 3; 960 | uint32 fly_count = 4; 961 | float gold_earn_sum = 5; 962 | uint32 round_count_sum = 6; 963 | float dadian_sum = 7; 964 | repeated RoundEndData round_end = 8; 965 | uint32 ming_count_sum = 9; 966 | uint32 liqi_count_sum = 10; 967 | uint32 xun_count_sum = 11; 968 | uint32 highest_lianzhuang = 12; 969 | uint32 score_earn_sum = 13; 970 | repeated RankScore rank_score = 14; 971 | message RoundEndData { 972 | uint32 type = 1; 973 | uint32 sum = 2; 974 | } 975 | 976 | message RankScore { 977 | uint32 rank = 1; 978 | int32 score_sum = 2; 979 | uint32 count = 3; 980 | } 981 | 982 | } 983 | 984 | message AccountStatisticByFan { 985 | uint32 fan_id = 1; 986 | uint32 sum = 2; 987 | } 988 | 989 | message AccountFanAchieved { 990 | uint32 mahjong_category = 1; 991 | repeated AccountStatisticByFan fan = 2; 992 | uint32 liujumanguan = 3; 993 | } 994 | 995 | message AccountDetailStatistic { 996 | repeated AccountStatisticByGameMode game_mode = 1; 997 | repeated AccountStatisticByFan fan = 2; 998 | uint32 liujumanguan = 3; 999 | repeated AccountFanAchieved fan_achieved = 4; 1000 | } 1001 | 1002 | message AccountDetailStatisticByCategory { 1003 | uint32 category = 1; 1004 | AccountDetailStatistic detail_statistic = 2; 1005 | } 1006 | 1007 | message AccountDetailStatisticV2 { 1008 | AccountDetailStatistic friend_room_statistic = 1; 1009 | RankStatistic rank_statistic = 2; 1010 | CustomizedContestStatistic customized_contest_statistic = 3; 1011 | AccountDetailStatistic leisure_match_statistic = 4; 1012 | ChallengeStatistic challenge_match_statistic = 5; 1013 | AccountDetailStatistic activity_match_statistic = 6; 1014 | AccountDetailStatistic ab_match_statistic = 7; 1015 | message RankStatistic { 1016 | RankData total_statistic = 1; 1017 | RankData month_statistic = 2; 1018 | uint32 month_refresh_time = 3; 1019 | message RankData { 1020 | AccountDetailStatistic all_level_statistic = 1; 1021 | repeated RankLevelData level_data_list = 2; 1022 | message RankLevelData { 1023 | uint32 rank_level = 1; 1024 | AccountDetailStatistic statistic = 2; 1025 | } 1026 | 1027 | } 1028 | 1029 | } 1030 | 1031 | message CustomizedContestStatistic { 1032 | AccountDetailStatistic total_statistic = 1; 1033 | AccountDetailStatistic month_statistic = 2; 1034 | uint32 month_refresh_time = 3; 1035 | } 1036 | 1037 | message ChallengeStatistic { 1038 | AccountDetailStatistic all_season = 1; 1039 | repeated SeasonData season_data_list = 2; 1040 | message SeasonData { 1041 | uint32 season_id = 1; 1042 | AccountDetailStatistic statistic = 2; 1043 | } 1044 | 1045 | } 1046 | 1047 | } 1048 | 1049 | message AccountShiLian { 1050 | uint32 step = 1; 1051 | uint32 state = 2; 1052 | } 1053 | 1054 | message ClientDeviceInfo { 1055 | string platform = 1; 1056 | string hardware = 2; 1057 | string os = 3; 1058 | string os_version = 4; 1059 | bool is_browser = 5; 1060 | string software = 6; 1061 | string sale_platform = 7; 1062 | string hardware_vendor = 8; 1063 | string model_number = 9; 1064 | } 1065 | 1066 | message ClientVersionInfo { 1067 | string resource = 1; 1068 | string package = 2; 1069 | } 1070 | 1071 | enum GamePlayerState { 1072 | NULL = 0; 1073 | AUTH = 1; 1074 | SYNCING = 2; 1075 | READY = 3; 1076 | } 1077 | 1078 | message Announcement { 1079 | uint32 id = 1; 1080 | string title = 2; 1081 | string content = 3; 1082 | } 1083 | 1084 | message TaskProgress { 1085 | uint32 id = 1; 1086 | uint32 counter = 2; 1087 | bool achieved = 3; 1088 | bool rewarded = 4; 1089 | bool failed = 5; 1090 | } 1091 | 1092 | message GameConfig { 1093 | uint32 category = 1; 1094 | GameMode mode = 2; 1095 | GameMetaData meta = 3; 1096 | } 1097 | 1098 | message RPGState { 1099 | uint32 player_damaged = 1; 1100 | uint32 monster_damaged = 2; 1101 | uint32 monster_seq = 3; 1102 | } 1103 | 1104 | message RPGActivity { 1105 | uint32 activity_id = 1; 1106 | string last_show_uuid = 5; 1107 | string last_played_uuid = 6; 1108 | RPGState current_state = 7; 1109 | RPGState last_show_state = 8; 1110 | repeated uint32 received_rewards = 9; 1111 | } 1112 | 1113 | message ActivityArenaData { 1114 | uint32 win_count = 1; 1115 | uint32 lose_count = 2; 1116 | uint32 activity_id = 3; 1117 | uint32 enter_time = 4; 1118 | uint32 daily_enter_count = 5; 1119 | uint32 daily_enter_time = 6; 1120 | uint32 max_win_count = 7; 1121 | uint32 total_win_count = 8; 1122 | } 1123 | 1124 | message FeedActivityData { 1125 | uint32 activity_id = 1; 1126 | uint32 feed_count = 2; 1127 | CountWithTimeData friend_receive_data = 3; 1128 | CountWithTimeData friend_send_data = 4; 1129 | repeated GiftBoxData gift_inbox = 5; 1130 | message CountWithTimeData { 1131 | uint32 count = 1; 1132 | uint32 last_update_time = 2; 1133 | } 1134 | 1135 | message GiftBoxData { 1136 | uint32 id = 1; 1137 | uint32 item_id = 2; 1138 | uint32 count = 3; 1139 | uint32 from_account_id = 4; 1140 | uint32 time = 5; 1141 | uint32 received = 6; 1142 | } 1143 | 1144 | } 1145 | 1146 | message SegmentTaskProgress { 1147 | uint32 id = 1; 1148 | uint32 counter = 2; 1149 | bool achieved = 3; 1150 | bool rewarded = 4; 1151 | bool failed = 5; 1152 | uint32 reward_count = 6; 1153 | uint32 achieved_count = 7; 1154 | } 1155 | 1156 | message MineActivityData { 1157 | repeated Point dig_point = 1; 1158 | repeated MineReward map = 2; 1159 | uint32 id = 3; 1160 | } 1161 | 1162 | message AccountActivityUpdate { 1163 | repeated lq.MineActivityData mine_data = 1; 1164 | repeated lq.RPGActivity rpg_data = 2; 1165 | repeated ActivityFeedData feed_data = 3; 1166 | } 1167 | 1168 | message ActivityFeedData { 1169 | uint32 activity_id = 1; 1170 | uint32 feed_count = 2; 1171 | CountWithTimeData friend_receive_data = 3; 1172 | CountWithTimeData friend_send_data = 4; 1173 | repeated GiftBoxData gift_inbox = 5; 1174 | uint32 max_inbox_id = 6; 1175 | message CountWithTimeData { 1176 | uint32 count = 1; 1177 | uint32 last_update_time = 2; 1178 | } 1179 | 1180 | message GiftBoxData { 1181 | uint32 id = 1; 1182 | uint32 item_id = 2; 1183 | uint32 count = 3; 1184 | uint32 from_account_id = 4; 1185 | uint32 time = 5; 1186 | uint32 received = 6; 1187 | } 1188 | 1189 | } 1190 | 1191 | message AccountActiveState { 1192 | uint32 account_id = 1; 1193 | uint32 login_time = 2; 1194 | uint32 logout_time = 3; 1195 | bool is_online = 4; 1196 | AccountPlayingGame playing = 5; 1197 | } 1198 | 1199 | message Friend { 1200 | PlayerBaseView base = 1; 1201 | AccountActiveState state = 2; 1202 | } 1203 | 1204 | message Point { 1205 | uint32 x = 1; 1206 | uint32 y = 2; 1207 | } 1208 | 1209 | message MineReward { 1210 | Point point = 1; 1211 | uint32 reward_id = 2; 1212 | bool received = 3; 1213 | } 1214 | 1215 | message GameLiveUnit { 1216 | uint32 timestamp = 1; 1217 | uint32 action_category = 2; 1218 | bytes action_data = 3; 1219 | } 1220 | 1221 | message GameLiveSegment { 1222 | repeated GameLiveUnit actions = 1; 1223 | } 1224 | 1225 | message GameLiveSegmentUri { 1226 | uint32 segment_id = 1; 1227 | string segment_uri = 2; 1228 | } 1229 | 1230 | message GameLiveHead { 1231 | string uuid = 1; 1232 | uint32 start_time = 2; 1233 | GameConfig game_config = 3; 1234 | repeated PlayerGameView players = 4; 1235 | repeated uint32 seat_list = 5; 1236 | } 1237 | 1238 | message GameNewRoundState { 1239 | repeated uint32 seat_states = 1; 1240 | } 1241 | 1242 | message GameEndAction { 1243 | uint32 state = 1; 1244 | } 1245 | 1246 | message GameNoopAction { 1247 | } 1248 | 1249 | message CommentItem { 1250 | uint32 comment_id = 1; 1251 | uint32 timestamp = 2; 1252 | PlayerBaseView commenter = 3; 1253 | string content = 4; 1254 | uint32 is_banned = 5; 1255 | } 1256 | 1257 | message RollingNotice { 1258 | uint32 id = 1; 1259 | string content = 2; 1260 | uint32 start_time = 3; 1261 | uint32 end_time = 4; 1262 | uint32 repeat_interval = 5; 1263 | string lang = 6; 1264 | } 1265 | 1266 | message BillingGoods { 1267 | string id = 1; 1268 | string name = 2; 1269 | string desc = 3; 1270 | string icon = 4; 1271 | uint32 resource_id = 5; 1272 | uint32 resource_count = 6; 1273 | } 1274 | 1275 | message BillShortcut { 1276 | uint32 id = 1; 1277 | uint32 count = 2; 1278 | uint32 dealPrice = 3; 1279 | } 1280 | 1281 | message BillingProduct { 1282 | BillingGoods goods = 1; 1283 | string currency_code = 2; 1284 | uint32 currency_price = 3; 1285 | uint32 sort_weight = 4; 1286 | } 1287 | 1288 | message Character { 1289 | uint32 charid = 1; 1290 | uint32 level = 2; 1291 | uint32 exp = 3; 1292 | repeated ViewSlot views = 4; 1293 | uint32 skin = 5; 1294 | bool is_upgraded = 6; 1295 | repeated uint32 extra_emoji = 7; 1296 | repeated uint32 rewarded_level = 8; 1297 | } 1298 | 1299 | message BuyRecord { 1300 | uint32 id = 1; 1301 | uint32 count = 2; 1302 | } 1303 | 1304 | message ZHPShop { 1305 | repeated uint32 goods = 1; 1306 | repeated BuyRecord buy_records = 2; 1307 | RefreshCount free_refresh = 3; 1308 | RefreshCount cost_refresh = 4; 1309 | message RefreshCount { 1310 | uint32 count = 1; 1311 | uint32 limit = 2; 1312 | } 1313 | 1314 | } 1315 | 1316 | message MonthTicketInfo { 1317 | uint32 id = 1; 1318 | uint32 end_time = 2; 1319 | uint32 last_pay_time = 3; 1320 | } 1321 | 1322 | message ShopInfo { 1323 | ZHPShop zhp = 1; 1324 | repeated BuyRecord buy_records = 2; 1325 | uint32 last_refresh_time = 3; 1326 | } 1327 | 1328 | message ChangeNicknameRecord { 1329 | string from = 1; 1330 | string to = 2; 1331 | uint32 time = 3; 1332 | } 1333 | 1334 | message ServerSettings { 1335 | PaymentSetting payment_setting = 3; 1336 | PaymentSettingV2 payment_setting_v2 = 4; 1337 | NicknameSetting nickname_setting = 5; 1338 | } 1339 | 1340 | message NicknameSetting { 1341 | uint32 enable = 1; 1342 | repeated string nicknames = 2; 1343 | } 1344 | 1345 | message PaymentSettingV2 { 1346 | uint32 open_payment = 1; 1347 | repeated PaymentSettingUnit payment_platforms = 2; 1348 | message PaymentMaintain { 1349 | uint32 start_time = 1; 1350 | uint32 end_time = 2; 1351 | uint32 goods_click_action = 3; 1352 | string goods_click_text = 4; 1353 | } 1354 | 1355 | message PaymentSettingUnit { 1356 | string platform = 1; 1357 | bool is_show = 2; 1358 | uint32 goods_click_action = 3; 1359 | string goods_click_text = 4; 1360 | PaymentMaintain maintain = 5; 1361 | bool enable_for_frozen_account = 6; 1362 | } 1363 | 1364 | } 1365 | 1366 | message PaymentSetting { 1367 | uint32 open_payment = 1; 1368 | uint32 payment_info_show_type = 2; 1369 | string payment_info = 3; 1370 | WechatData wechat = 4; 1371 | AlipayData alipay = 5; 1372 | message WechatData { 1373 | bool disable_create = 1; 1374 | uint32 payment_source_platform = 2; 1375 | bool enable_credit = 3; 1376 | } 1377 | 1378 | message AlipayData { 1379 | bool disable_create = 1; 1380 | uint32 payment_source_platform = 2; 1381 | } 1382 | 1383 | } 1384 | 1385 | message AccountSetting { 1386 | uint32 key = 1; 1387 | uint32 value = 2; 1388 | } 1389 | 1390 | message ChestData { 1391 | uint32 chest_id = 1; 1392 | uint32 total_open_count = 2; 1393 | uint32 consume_count = 3; 1394 | uint32 face_black_count = 4; 1395 | } 1396 | 1397 | message ChestDataV2 { 1398 | uint32 chest_id = 1; 1399 | uint32 total_open_count = 2; 1400 | uint32 face_black_count = 3; 1401 | } 1402 | 1403 | message FaithData { 1404 | uint32 faith_id = 1; 1405 | uint32 total_open_count = 2; 1406 | uint32 consume_count = 3; 1407 | int32 modify_count = 4; 1408 | } 1409 | 1410 | message CustomizedContestBase { 1411 | uint32 unique_id = 1; 1412 | uint32 contest_id = 2; 1413 | string contest_name = 3; 1414 | uint32 state = 4; 1415 | uint32 creator_id = 5; 1416 | uint32 create_time = 6; 1417 | uint32 start_time = 7; 1418 | uint32 finish_time = 8; 1419 | bool open = 9; 1420 | uint32 contest_type = 10; 1421 | } 1422 | 1423 | message CustomizedContestExtend { 1424 | uint32 unique_id = 1; 1425 | string public_notice = 2; 1426 | } 1427 | 1428 | message CustomizedContestAbstract { 1429 | uint32 unique_id = 1; 1430 | uint32 contest_id = 2; 1431 | string contest_name = 3; 1432 | uint32 state = 4; 1433 | uint32 creator_id = 5; 1434 | uint32 create_time = 6; 1435 | uint32 start_time = 7; 1436 | uint32 finish_time = 8; 1437 | bool open = 9; 1438 | string public_notice = 10; 1439 | uint32 contest_type = 11; 1440 | } 1441 | 1442 | message CustomizedContestDetail { 1443 | uint32 unique_id = 1; 1444 | uint32 contest_id = 2; 1445 | string contest_name = 3; 1446 | uint32 state = 4; 1447 | uint32 creator_id = 5; 1448 | uint32 create_time = 6; 1449 | uint32 start_time = 7; 1450 | uint32 finish_time = 8; 1451 | bool open = 9; 1452 | uint32 rank_rule = 10; 1453 | GameMode game_mode = 11; 1454 | string private_notice = 12; 1455 | uint32 observer_switch = 13; 1456 | uint32 emoji_switch = 14; 1457 | uint32 contest_type = 15; 1458 | } 1459 | 1460 | message CustomizedContestPlayerReport { 1461 | uint32 rank_rule = 1; 1462 | uint32 rank = 2; 1463 | int32 point = 3; 1464 | repeated uint32 game_ranks = 4; 1465 | uint32 total_game_count = 5; 1466 | } 1467 | 1468 | message RecordGame { 1469 | string uuid = 1; 1470 | uint32 start_time = 2; 1471 | uint32 end_time = 3; 1472 | GameConfig config = 5; 1473 | repeated AccountInfo accounts = 11; 1474 | GameEndResult result = 12; 1475 | message AccountInfo { 1476 | uint32 account_id = 1; 1477 | uint32 seat = 2; 1478 | string nickname = 3; 1479 | uint32 avatar_id = 4; 1480 | Character character = 5; 1481 | uint32 title = 6; 1482 | AccountLevel level = 7; 1483 | AccountLevel level3 = 8; 1484 | uint32 avatar_frame = 9; 1485 | uint32 verified = 10; 1486 | repeated ViewSlot views = 11; 1487 | } 1488 | 1489 | } 1490 | 1491 | message CustomizedContestGameStart { 1492 | repeated Item players = 1; 1493 | message Item { 1494 | uint32 account_id = 1; 1495 | string nickname = 2; 1496 | } 1497 | 1498 | } 1499 | 1500 | message CustomizedContestGameEnd { 1501 | repeated Item players = 1; 1502 | message Item { 1503 | uint32 account_id = 1; 1504 | string nickname = 2; 1505 | int32 total_point = 3; 1506 | } 1507 | 1508 | } 1509 | 1510 | message Activity { 1511 | uint32 activity_id = 1; 1512 | uint32 start_time = 2; 1513 | uint32 end_time = 3; 1514 | string type = 4; 1515 | } 1516 | 1517 | message ExchangeRecord { 1518 | uint32 exchange_id = 1; 1519 | uint32 count = 2; 1520 | } 1521 | 1522 | message ActivityAccumulatedPointData { 1523 | uint32 activity_id = 1; 1524 | int32 point = 2; 1525 | repeated uint32 gained_reward_list = 3; 1526 | } 1527 | 1528 | message ActivityRankPointData { 1529 | uint32 leaderboard_id = 1; 1530 | int32 point = 2; 1531 | bool gained_reward = 3; 1532 | uint32 gainable_time = 4; 1533 | } 1534 | 1535 | message GameRoundHuData { 1536 | HuPai hupai = 1; 1537 | repeated Fan fans = 2; 1538 | uint32 score = 3; 1539 | uint32 xun = 4; 1540 | uint32 title_id = 5; 1541 | uint32 fan_sum = 6; 1542 | uint32 fu_sum = 7; 1543 | uint32 yakuman_count = 8; 1544 | uint32 biao_dora_count = 9; 1545 | uint32 red_dora_count = 10; 1546 | uint32 li_dora_count = 11; 1547 | uint32 babei_count = 12; 1548 | uint32 xuan_shang_count = 13; 1549 | message HuPai { 1550 | string tile = 1; 1551 | uint32 seat = 2; 1552 | uint32 liqi = 3; 1553 | } 1554 | 1555 | message Fan { 1556 | uint32 id = 1; 1557 | uint32 count = 2; 1558 | uint32 fan = 3; 1559 | } 1560 | 1561 | } 1562 | 1563 | message GameRoundPlayerResult { 1564 | uint32 type = 1; 1565 | repeated string hands = 2; 1566 | repeated string ming = 3; 1567 | uint32 liqi_type = 4; 1568 | bool is_fulu = 5; 1569 | bool is_liujumanguan = 6; 1570 | uint32 lian_zhuang = 7; 1571 | GameRoundHuData hu = 8; 1572 | } 1573 | 1574 | message GameRoundPlayer { 1575 | int32 score = 1; 1576 | uint32 rank = 2; 1577 | GameRoundPlayerResult result = 3; 1578 | } 1579 | 1580 | message GameRoundSnapshot { 1581 | uint32 ju = 1; 1582 | uint32 ben = 2; 1583 | repeated GameRoundPlayer players = 3; 1584 | } 1585 | 1586 | message GameFinalSnapshot { 1587 | string uuid = 1; 1588 | uint32 state = 2; 1589 | uint32 category = 3; 1590 | GameMode mode = 4; 1591 | GameMetaData meta = 5; 1592 | CalculateParam calculate_param = 6; 1593 | uint32 create_time = 7; 1594 | uint32 start_time = 8; 1595 | uint32 finish_time = 9; 1596 | repeated GameSeat seats = 10; 1597 | repeated GameRoundSnapshot rounds = 11; 1598 | repeated PlayerGameView account_views = 12; 1599 | repeated FinalPlayer final_players = 13; 1600 | repeated AFKInfo afk_info = 14; 1601 | message CalculateParam { 1602 | uint32 init_point = 1; 1603 | uint32 jingsuanyuandian = 2; 1604 | repeated int32 rank_points = 3; 1605 | } 1606 | 1607 | message GameSeat { 1608 | uint32 type = 1; 1609 | uint32 account_id = 2; 1610 | NetworkEndpoint notify_endpoint = 3; 1611 | string client_address = 4; 1612 | bool is_connected = 5; 1613 | } 1614 | 1615 | message FinalPlayer { 1616 | uint32 seat = 1; 1617 | int32 total_point = 2; 1618 | int32 part_point_1 = 3; 1619 | int32 part_point_2 = 4; 1620 | int32 grading_score = 5; 1621 | int32 gold = 6; 1622 | } 1623 | 1624 | message AFKInfo { 1625 | uint32 deal_tile_count = 1; 1626 | uint32 moqie_count = 2; 1627 | uint32 seat = 3; 1628 | } 1629 | 1630 | } 1631 | 1632 | message RecordCollectedData { 1633 | string uuid = 1; 1634 | string remarks = 2; 1635 | uint32 start_time = 3; 1636 | uint32 end_time = 4; 1637 | } 1638 | 1639 | message ContestDetailRule { 1640 | uint32 init_point = 5; 1641 | uint32 fandian = 6; 1642 | bool can_jifei = 7; 1643 | uint32 tianbian_value = 8; 1644 | uint32 liqibang_value = 9; 1645 | uint32 changbang_value = 10; 1646 | uint32 noting_fafu_1 = 11; 1647 | uint32 noting_fafu_2 = 12; 1648 | uint32 noting_fafu_3 = 13; 1649 | bool have_liujumanguan = 14; 1650 | bool have_qieshangmanguan = 15; 1651 | bool have_biao_dora = 16; 1652 | bool have_gang_biao_dora = 17; 1653 | bool ming_dora_immediately_open = 18; 1654 | bool have_li_dora = 19; 1655 | bool have_gang_li_dora = 20; 1656 | bool have_sifenglianda = 21; 1657 | bool have_sigangsanle = 22; 1658 | bool have_sijializhi = 23; 1659 | bool have_jiuzhongjiupai = 24; 1660 | bool have_sanjiahele = 25; 1661 | bool have_toutiao = 26; 1662 | bool have_helelianzhuang = 27; 1663 | bool have_helezhongju = 28; 1664 | bool have_tingpailianzhuang = 29; 1665 | bool have_tingpaizhongju = 30; 1666 | bool have_yifa = 31; 1667 | bool have_nanruxiru = 32; 1668 | uint32 jingsuanyuandian = 33; 1669 | int32 shunweima_2 = 34; 1670 | int32 shunweima_3 = 35; 1671 | int32 shunweima_4 = 36; 1672 | bool bianjietishi = 37; 1673 | uint32 ai_level = 38; 1674 | bool have_zimosun = 39; 1675 | bool disable_multi_yukaman = 40; 1676 | uint32 guyi_mode = 41; 1677 | bool disable_leijiyiman = 42; 1678 | } 1679 | 1680 | message ContestDetailRuleV2 { 1681 | ContestDetailRule game_rule = 1; 1682 | ExtraRule extra_rule = 2; 1683 | message ExtraRule { 1684 | uint32 required_level = 1; 1685 | uint32 max_game_count = 2; 1686 | } 1687 | 1688 | } 1689 | 1690 | message GameRuleSetting { 1691 | uint32 round_type = 1; 1692 | bool shiduan = 2; 1693 | uint32 dora_count = 3; 1694 | uint32 thinking_type = 4; 1695 | bool use_detail_rule = 5; 1696 | ContestDetailRuleV2 detail_rule_v2 = 6; 1697 | } 1698 | 1699 | message RecordTingPaiInfo { 1700 | string tile = 1; 1701 | bool haveyi = 2; 1702 | bool yiman = 3; 1703 | uint32 count = 4; 1704 | uint32 fu = 5; 1705 | uint32 biao_dora_count = 6; 1706 | bool yiman_zimo = 7; 1707 | uint32 count_zimo = 8; 1708 | uint32 fu_zimo = 9; 1709 | } 1710 | 1711 | message RecordNoTilePlayerInfo { 1712 | bool tingpai = 3; 1713 | repeated string hand = 4; 1714 | repeated RecordTingPaiInfo tings = 5; 1715 | bool liuman = 6; 1716 | } 1717 | 1718 | message RecordHuleInfo { 1719 | repeated string hand = 1; 1720 | repeated string ming = 2; 1721 | string hu_tile = 3; 1722 | uint32 seat = 4; 1723 | bool zimo = 5; 1724 | bool qinjia = 6; 1725 | bool liqi = 7; 1726 | repeated string doras = 8; 1727 | repeated string li_doras = 9; 1728 | bool yiman = 10; 1729 | uint32 count = 11; 1730 | repeated RecordFanInfo fans = 12; 1731 | uint32 fu = 13; 1732 | uint32 point_zimo_qin = 14; 1733 | uint32 point_zimo_xian = 15; 1734 | uint32 title_id = 16; 1735 | uint32 point_sum = 17; 1736 | uint32 dadian = 18; 1737 | bool is_jue_zhang = 19; 1738 | uint32 xun = 20; 1739 | uint32 ting_type = 21; 1740 | message RecordFanInfo { 1741 | uint32 val = 1; 1742 | uint32 id = 2; 1743 | } 1744 | 1745 | } 1746 | 1747 | message RecordHulesInfo { 1748 | int32 seat = 1; 1749 | repeated RecordHuleInfo hules = 2; 1750 | } 1751 | 1752 | message RecordLiujuInfo { 1753 | uint32 seat = 1; 1754 | uint32 type = 2; 1755 | } 1756 | 1757 | message RecordNoTileInfo { 1758 | bool liujumanguan = 1; 1759 | repeated RecordNoTilePlayerInfo players = 2; 1760 | } 1761 | 1762 | message RecordLiqiInfo { 1763 | uint32 seat = 1; 1764 | uint32 score = 2; 1765 | bool is_w = 3; 1766 | bool is_zhen_ting = 4; 1767 | uint32 xun = 5; 1768 | bool is_success = 6; 1769 | } 1770 | 1771 | message RecordGangInfo { 1772 | uint32 seat = 1; 1773 | uint32 type = 2; 1774 | string pai = 3; 1775 | bool is_dora = 4; 1776 | uint32 xun = 5; 1777 | } 1778 | 1779 | message RecordBaBeiInfo { 1780 | uint32 seat = 1; 1781 | bool is_zi_mo = 2; 1782 | bool is_chong = 3; 1783 | bool is_bei = 4; 1784 | } 1785 | 1786 | message RecordPeiPaiInfo { 1787 | uint32 dora_count = 1; 1788 | uint32 r_dora_count = 2; 1789 | uint32 bei_count = 3; 1790 | } 1791 | 1792 | message RecordRoundInfo { 1793 | string name = 1; 1794 | uint32 chang = 2; 1795 | uint32 ju = 3; 1796 | uint32 ben = 4; 1797 | repeated uint32 scores = 5; 1798 | repeated RecordLiqiInfo liqi_infos = 7; 1799 | repeated RecordGangInfo gang_infos = 8; 1800 | repeated RecordPeiPaiInfo peipai_infos = 9; 1801 | repeated RecordBaBeiInfo babai_infos = 10; 1802 | RecordHulesInfo hules_info = 11; 1803 | RecordLiujuInfo liuju_info = 12; 1804 | RecordNoTileInfo no_tile_info = 13; 1805 | } 1806 | 1807 | message RecordAnalysisedData { 1808 | repeated RecordRoundInfo round_infos = 1; 1809 | } 1810 | 1811 | message NotifyCaptcha { 1812 | uint32 check_id = 1; 1813 | uint32 start_time = 2; 1814 | string random_str = 3; 1815 | uint32 type = 4; 1816 | } 1817 | 1818 | message NotifyRoomGameStart { 1819 | string game_url = 1; 1820 | string connect_token = 2; 1821 | string game_uuid = 3; 1822 | string location = 4; 1823 | } 1824 | 1825 | message NotifyMatchGameStart { 1826 | string game_url = 1; 1827 | string connect_token = 2; 1828 | string game_uuid = 3; 1829 | uint32 match_mode_id = 4; 1830 | string location = 5; 1831 | } 1832 | 1833 | message NotifyRoomPlayerReady { 1834 | uint32 account_id = 1; 1835 | bool ready = 2; 1836 | AccountReadyState account_list = 3; 1837 | uint32 seq = 4; 1838 | message AccountReadyState { 1839 | uint32 account_id = 1; 1840 | bool ready = 2; 1841 | } 1842 | 1843 | } 1844 | 1845 | message NotifyRoomPlayerDressing { 1846 | uint32 account_id = 1; 1847 | bool dressing = 2; 1848 | AccountDressingState account_list = 3; 1849 | uint32 seq = 4; 1850 | message AccountDressingState { 1851 | uint32 account_id = 1; 1852 | bool dressing = 2; 1853 | } 1854 | 1855 | } 1856 | 1857 | message NotifyRoomPlayerUpdate { 1858 | repeated PlayerBaseView update_list = 1; 1859 | repeated uint32 remove_list = 2; 1860 | uint32 owner_id = 3; 1861 | uint32 robot_count = 4; 1862 | repeated PlayerBaseView player_list = 5; 1863 | uint32 seq = 6; 1864 | } 1865 | 1866 | message NotifyRoomKickOut { 1867 | } 1868 | 1869 | message NotifyFriendStateChange { 1870 | uint32 target_id = 1; 1871 | AccountActiveState active_state = 2; 1872 | } 1873 | 1874 | message NotifyFriendViewChange { 1875 | uint32 target_id = 1; 1876 | PlayerBaseView base = 2; 1877 | } 1878 | 1879 | message NotifyFriendChange { 1880 | uint32 account_id = 1; 1881 | uint32 type = 2; 1882 | Friend friend = 3; 1883 | } 1884 | 1885 | message NotifyNewFriendApply { 1886 | uint32 account_id = 1; 1887 | uint32 apply_time = 2; 1888 | uint32 removed_id = 3; 1889 | } 1890 | 1891 | message NotifyClientMessage { 1892 | PlayerBaseView sender = 1; 1893 | uint32 type = 2; 1894 | string content = 3; 1895 | } 1896 | 1897 | message NotifyAccountUpdate { 1898 | AccountUpdate update = 1; 1899 | } 1900 | 1901 | message NotifyAnotherLogin { 1902 | } 1903 | 1904 | message NotifyAccountLogout { 1905 | } 1906 | 1907 | message NotifyAnnouncementUpdate { 1908 | repeated AnnouncementUpdate update_list = 1; 1909 | message AnnouncementUpdate { 1910 | string lang = 1; 1911 | string platform = 2; 1912 | } 1913 | 1914 | } 1915 | 1916 | message NotifyNewMail { 1917 | Mail mail = 1; 1918 | } 1919 | 1920 | message NotifyDeleteMail { 1921 | repeated uint32 mail_id_list = 1; 1922 | } 1923 | 1924 | message NotifyReviveCoinUpdate { 1925 | bool has_gained = 1; 1926 | } 1927 | 1928 | message NotifyDailyTaskUpdate { 1929 | repeated TaskProgress progresses = 1; 1930 | uint32 max_daily_task_count = 2; 1931 | uint32 refresh_count = 3; 1932 | } 1933 | 1934 | message NotifyActivityTaskUpdate { 1935 | repeated TaskProgress progresses = 1; 1936 | } 1937 | 1938 | message NotifyActivityPeriodTaskUpdate { 1939 | repeated TaskProgress progresses = 1; 1940 | } 1941 | 1942 | message NotifyAccountRandomTaskUpdate { 1943 | repeated TaskProgress progresses = 1; 1944 | } 1945 | 1946 | message NotifyActivitySegmentTaskUpdate { 1947 | repeated lq.SegmentTaskProgress progresses = 1; 1948 | } 1949 | 1950 | message NotifyActivityUpdate { 1951 | repeated FeedActivityData list = 1; 1952 | message FeedActivityData { 1953 | uint32 activity_id = 1; 1954 | uint32 feed_count = 2; 1955 | CountWithTimeData friend_receive_data = 3; 1956 | CountWithTimeData friend_send_data = 4; 1957 | repeated GiftBoxData gift_inbox = 5; 1958 | message CountWithTimeData { 1959 | uint32 count = 1; 1960 | uint32 last_update_time = 2; 1961 | } 1962 | 1963 | message GiftBoxData { 1964 | uint32 id = 1; 1965 | uint32 item_id = 2; 1966 | uint32 count = 3; 1967 | uint32 from_account_id = 4; 1968 | uint32 time = 5; 1969 | uint32 received = 6; 1970 | } 1971 | 1972 | } 1973 | 1974 | } 1975 | 1976 | message NotifyAccountChallengeTaskUpdate { 1977 | repeated TaskProgress progresses = 1; 1978 | uint32 level = 2; 1979 | uint32 refresh_count = 3; 1980 | uint32 match_count = 4; 1981 | uint32 ticket_id = 5; 1982 | repeated uint32 rewarded_season = 6; 1983 | } 1984 | 1985 | message NotifyNewComment { 1986 | } 1987 | 1988 | message NotifyRollingNotice { 1989 | RollingNotice notice = 1; 1990 | } 1991 | 1992 | message NotifyGiftSendRefresh { 1993 | } 1994 | 1995 | message NotifyShopUpdate { 1996 | ShopInfo shop_info = 1; 1997 | } 1998 | 1999 | message NotifyVipLevelChange { 2000 | uint32 gift_limit = 1; 2001 | uint32 friend_max_count = 2; 2002 | uint32 zhp_free_refresh_limit = 3; 2003 | uint32 zhp_cost_refresh_limit = 4; 2004 | float buddy_bonus = 5; 2005 | uint32 record_collect_limit = 6; 2006 | } 2007 | 2008 | message NotifyServerSetting { 2009 | ServerSettings settings = 1; 2010 | } 2011 | 2012 | message NotifyPayResult { 2013 | uint32 pay_result = 1; 2014 | string order_id = 2; 2015 | uint32 goods_id = 3; 2016 | uint32 new_month_ticket = 4; 2017 | repeated ResourceModify resource_modify = 5; 2018 | message ResourceModify { 2019 | uint32 id = 1; 2020 | uint32 count = 2; 2021 | uint32 final = 3; 2022 | } 2023 | 2024 | } 2025 | 2026 | message NotifyCustomContestAccountMsg { 2027 | uint32 unique_id = 1; 2028 | uint32 account_id = 2; 2029 | string sender = 3; 2030 | string content = 4; 2031 | uint32 verified = 5; 2032 | } 2033 | 2034 | message NotifyCustomContestSystemMsg { 2035 | uint32 unique_id = 1; 2036 | uint32 type = 2; 2037 | string uuid = 3; 2038 | CustomizedContestGameStart game_start = 4; 2039 | CustomizedContestGameEnd game_end = 5; 2040 | } 2041 | 2042 | message NotifyMatchTimeout { 2043 | string sid = 1; 2044 | } 2045 | 2046 | message NotifyCustomContestState { 2047 | uint32 unique_id = 1; 2048 | uint32 state = 2; 2049 | } 2050 | 2051 | message NotifyActivityChange { 2052 | repeated Activity new_activities = 1; 2053 | repeated uint32 end_activities = 2; 2054 | } 2055 | 2056 | message NotifyAFKResult { 2057 | uint32 type = 1; 2058 | uint32 ban_end_time = 2; 2059 | string game_uuid = 3; 2060 | } 2061 | 2062 | message NotifyGameFinishRewardV2 { 2063 | uint32 mode_id = 1; 2064 | LevelChange level_change = 2; 2065 | MatchChest match_chest = 3; 2066 | MainCharacter main_character = 4; 2067 | CharacterGift character_gift = 5; 2068 | message LevelChange { 2069 | AccountLevel origin = 1; 2070 | AccountLevel final = 2; 2071 | uint32 type = 3; 2072 | } 2073 | 2074 | message MatchChest { 2075 | uint32 chest_id = 1; 2076 | uint32 origin = 2; 2077 | uint32 final = 3; 2078 | bool is_graded = 4; 2079 | repeated RewardSlot rewards = 5; 2080 | } 2081 | 2082 | message MainCharacter { 2083 | uint32 level = 1; 2084 | uint32 exp = 2; 2085 | uint32 add = 3; 2086 | } 2087 | 2088 | message CharacterGift { 2089 | uint32 origin = 1; 2090 | uint32 final = 2; 2091 | uint32 add = 3; 2092 | bool is_graded = 4; 2093 | } 2094 | 2095 | } 2096 | 2097 | message NotifyActivityRewardV2 { 2098 | repeated ActivityReward activity_reward = 1; 2099 | message ActivityReward { 2100 | uint32 activity_id = 1; 2101 | repeated RewardSlot rewards = 2; 2102 | } 2103 | 2104 | } 2105 | 2106 | message NotifyActivityPointV2 { 2107 | repeated ActivityPoint activity_points = 1; 2108 | message ActivityPoint { 2109 | uint32 activity_id = 1; 2110 | uint32 point = 2; 2111 | } 2112 | 2113 | } 2114 | 2115 | message NotifyLeaderboardPointV2 { 2116 | repeated LeaderboardPoint leaderboard_points = 1; 2117 | message LeaderboardPoint { 2118 | uint32 leaderboard_id = 1; 2119 | uint32 point = 2; 2120 | } 2121 | 2122 | } 2123 | 2124 | -------------------------------------------------------------------------------- /ms_tournament/rpc.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | # Generated. DO NOT EDIT! 3 | 4 | import ms_tournament.protocol_admin_pb2 as pb 5 | from ms_tournament.base import MSRPCService 6 | 7 | 8 | class CustomizedContestManagerApi(MSRPCService): 9 | version = None 10 | 11 | _req = { 12 | 'loginContestManager': pb.ReqContestManageLogin, 13 | 'oauth2AuthContestManager': pb.ReqContestManageOauth2Auth, 14 | 'oauth2LoginContestManager': pb.ReqContestManageOauth2Login, 15 | 'logoutContestManager': pb.ReqCommon, 16 | 'fetchRelatedContestList': pb.ReqCommon, 17 | 'createContest': pb.ReqCreateCustomizedContest, 18 | 'deleteContest': pb.ReqDeleteCustomizedContest, 19 | 'prolongContest': pb.ReqProlongContest, 20 | 'manageContest': pb.ReqManageContest, 21 | 'fetchContestInfo': pb.ReqCommon, 22 | 'exitManageContest': pb.ReqCommon, 23 | 'fetchContestGameRule': pb.ReqCommon, 24 | 'updateContestGameRule': pb.ReqUpdateContestGameRule, 25 | 'searchAccountByNickname': pb.ReqSearchAccountByNickname, 26 | 'searchAccountByEid': pb.ReqSearchAccountByEid, 27 | 'fetchContestPlayer': pb.ReqCommon, 28 | 'updateContestPlayer': pb.ReqUpdateCustomizedContestPlayer, 29 | 'startManageGame': pb.ReqCommon, 30 | 'stopManageGame': pb.ReqCommon, 31 | 'lockGamePlayer': pb.ReqLockGamePlayer, 32 | 'unlockGamePlayer': pb.ReqUnlockGamePlayer, 33 | 'createContestGame': pb.ReqCreateContestGame, 34 | 'fetchContestGameRecords': pb.ReqFetchCustomizedContestGameRecordList, 35 | 'removeContestGameRecord': pb.ReqRemoveContestGameRecord, 36 | 'fetchContestNotice': pb.ReqFetchContestNotice, 37 | 'updateContestNotice': pb.ReqUpdateCustomizedContestNotice, 38 | 'fetchContestManager': pb.ReqCommon, 39 | 'updateContestManager': pb.ReqUpdateCustomizedContestManager, 40 | 'fetchChatSetting': pb.ReqCommon, 41 | 'updateChatSetting': pb.ReqUpdateCustomizedContestChatSetting, 42 | 'updateGameTag': pb.ReqUpdateGameTag, 43 | 'terminateGame': pb.ReqTerminateContestGame, 44 | 'pauseGame': pb.ReqPauseContestGame, 45 | 'resumeGame': pb.ReqResumeContestGame, 46 | 'fetchCurrentRankList': pb.ReqCommon, 47 | 'fetchContestLastModify': pb.ReqCommon, 48 | 'fetchContestObserver': pb.ReqCommon, 49 | 'addContestObserver': pb.ReqAddContestObserver, 50 | 'removeContestObserver': pb.ReqRemoveContestObserver, 51 | 'fetchContestChatHistory': pb.ReqCommon, 52 | 'clearChatHistory': pb.ReqClearChatHistory, 53 | } 54 | _res = { 55 | 'loginContestManager': pb.ResContestManageLogin, 56 | 'oauth2AuthContestManager': pb.ResContestManageOauth2Auth, 57 | 'oauth2LoginContestManager': pb.ResContestManageOauth2Login, 58 | 'logoutContestManager': pb.ResCommon, 59 | 'fetchRelatedContestList': pb.ResFetchRelatedContestList, 60 | 'createContest': pb.ResCreateCustomizedContest, 61 | 'deleteContest': pb.ResCommon, 62 | 'prolongContest': pb.ResProlongContest, 63 | 'manageContest': pb.ResManageContest, 64 | 'fetchContestInfo': pb.ResManageContest, 65 | 'exitManageContest': pb.ResCommon, 66 | 'fetchContestGameRule': pb.ResFetchContestGameRule, 67 | 'updateContestGameRule': pb.ResCommon, 68 | 'searchAccountByNickname': pb.ResSearchAccountByNickname, 69 | 'searchAccountByEid': pb.ResSearchAccountByEid, 70 | 'fetchContestPlayer': pb.ResFetchCustomizedContestPlayer, 71 | 'updateContestPlayer': pb.ResCommon, 72 | 'startManageGame': pb.ResStartManageGame, 73 | 'stopManageGame': pb.ResCommon, 74 | 'lockGamePlayer': pb.ResCommon, 75 | 'unlockGamePlayer': pb.ResCommon, 76 | 'createContestGame': pb.ResCreateContestGame, 77 | 'fetchContestGameRecords': pb.ResFetchCustomizedContestGameRecordList, 78 | 'removeContestGameRecord': pb.ResCommon, 79 | 'fetchContestNotice': pb.ResFetchContestNotice, 80 | 'updateContestNotice': pb.ResCommon, 81 | 'fetchContestManager': pb.ResFetchCustomizedContestManager, 82 | 'updateContestManager': pb.ResCommon, 83 | 'fetchChatSetting': pb.ResCustomizedContestChatInfo, 84 | 'updateChatSetting': pb.ResUpdateCustomizedContestChatSetting, 85 | 'updateGameTag': pb.ResCommon, 86 | 'terminateGame': pb.ResCommon, 87 | 'pauseGame': pb.ResCommon, 88 | 'resumeGame': pb.ResCommon, 89 | 'fetchCurrentRankList': pb.ResFetchCurrentRankList, 90 | 'fetchContestLastModify': pb.ResFetchContestLastModify, 91 | 'fetchContestObserver': pb.ResFetchContestObserver, 92 | 'addContestObserver': pb.ResAddContestObserver, 93 | 'removeContestObserver': pb.ResCommon, 94 | 'fetchContestChatHistory': pb.ResFetchContestChatHistory, 95 | 'clearChatHistory': pb.ResCommon, 96 | } 97 | 98 | def get_package_name(self): 99 | return 'lq' 100 | 101 | def get_service_name(self): 102 | return 'CustomizedContestManagerApi' 103 | 104 | def get_req_class(self, method): 105 | return CustomizedContestManagerApi._req[method] 106 | 107 | def get_res_class(self, method): 108 | return CustomizedContestManagerApi._res[method] 109 | 110 | async def login_contest_manager(self, req): 111 | return await self.call_method('loginContestManager', req) 112 | 113 | async def oauth2_auth_contest_manager(self, req): 114 | return await self.call_method('oauth2AuthContestManager', req) 115 | 116 | async def oauth2_login_contest_manager(self, req): 117 | return await self.call_method('oauth2LoginContestManager', req) 118 | 119 | async def logout_contest_manager(self, req): 120 | return await self.call_method('logoutContestManager', req) 121 | 122 | async def fetch_related_contest_list(self, req): 123 | return await self.call_method('fetchRelatedContestList', req) 124 | 125 | async def create_contest(self, req): 126 | return await self.call_method('createContest', req) 127 | 128 | async def delete_contest(self, req): 129 | return await self.call_method('deleteContest', req) 130 | 131 | async def prolong_contest(self, req): 132 | return await self.call_method('prolongContest', req) 133 | 134 | async def manage_contest(self, req): 135 | return await self.call_method('manageContest', req) 136 | 137 | async def fetch_contest_info(self, req): 138 | return await self.call_method('fetchContestInfo', req) 139 | 140 | async def exit_manage_contest(self, req): 141 | return await self.call_method('exitManageContest', req) 142 | 143 | async def fetch_contest_game_rule(self, req): 144 | return await self.call_method('fetchContestGameRule', req) 145 | 146 | async def update_contest_game_rule(self, req): 147 | return await self.call_method('updateContestGameRule', req) 148 | 149 | async def search_account_by_nickname(self, req): 150 | return await self.call_method('searchAccountByNickname', req) 151 | 152 | async def search_account_by_eid(self, req): 153 | return await self.call_method('searchAccountByEid', req) 154 | 155 | async def fetch_contest_player(self, req): 156 | return await self.call_method('fetchContestPlayer', req) 157 | 158 | async def update_contest_player(self, req): 159 | return await self.call_method('updateContestPlayer', req) 160 | 161 | async def start_manage_game(self, req): 162 | return await self.call_method('startManageGame', req) 163 | 164 | async def stop_manage_game(self, req): 165 | return await self.call_method('stopManageGame', req) 166 | 167 | async def lock_game_player(self, req): 168 | return await self.call_method('lockGamePlayer', req) 169 | 170 | async def unlock_game_player(self, req): 171 | return await self.call_method('unlockGamePlayer', req) 172 | 173 | async def create_contest_game(self, req): 174 | return await self.call_method('createContestGame', req) 175 | 176 | async def fetch_contest_game_records(self, req): 177 | return await self.call_method('fetchContestGameRecords', req) 178 | 179 | async def remove_contest_game_record(self, req): 180 | return await self.call_method('removeContestGameRecord', req) 181 | 182 | async def fetch_contest_notice(self, req): 183 | return await self.call_method('fetchContestNotice', req) 184 | 185 | async def update_contest_notice(self, req): 186 | return await self.call_method('updateContestNotice', req) 187 | 188 | async def fetch_contest_manager(self, req): 189 | return await self.call_method('fetchContestManager', req) 190 | 191 | async def update_contest_manager(self, req): 192 | return await self.call_method('updateContestManager', req) 193 | 194 | async def fetch_chat_setting(self, req): 195 | return await self.call_method('fetchChatSetting', req) 196 | 197 | async def update_chat_setting(self, req): 198 | return await self.call_method('updateChatSetting', req) 199 | 200 | async def update_game_tag(self, req): 201 | return await self.call_method('updateGameTag', req) 202 | 203 | async def terminate_game(self, req): 204 | return await self.call_method('terminateGame', req) 205 | 206 | async def pause_game(self, req): 207 | return await self.call_method('pauseGame', req) 208 | 209 | async def resume_game(self, req): 210 | return await self.call_method('resumeGame', req) 211 | 212 | async def fetch_current_rank_list(self, req): 213 | return await self.call_method('fetchCurrentRankList', req) 214 | 215 | async def fetch_contest_last_modify(self, req): 216 | return await self.call_method('fetchContestLastModify', req) 217 | 218 | async def fetch_contest_observer(self, req): 219 | return await self.call_method('fetchContestObserver', req) 220 | 221 | async def add_contest_observer(self, req): 222 | return await self.call_method('addContestObserver', req) 223 | 224 | async def remove_contest_observer(self, req): 225 | return await self.call_method('removeContestObserver', req) 226 | 227 | async def fetch_contest_chat_history(self, req): 228 | return await self.call_method('fetchContestChatHistory', req) 229 | 230 | async def clear_chat_history(self, req): 231 | return await self.call_method('clearChatHistory', req) 232 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | protobuf==4.22.3 2 | websockets==11.0.2 3 | aiohttp==3.9.0 4 | -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- 1 | import setuptools 2 | 3 | from distutils.core import setup 4 | 5 | setup( 6 | name='ms_api', 7 | packages=[ 8 | 'ms', 9 | 'ms_tournament', 10 | ], 11 | version='0.10.275', 12 | description='Python wrapper for the Mahjong Soul (Majsoul) Protobuf objects. It allows to use their API.', 13 | long_description='', 14 | author='Nihisil', 15 | author_email='alexey@nihisil.com', 16 | url='https://github.com/MahjongRepository/mahjong_soul_api', 17 | install_requires=[ 18 | 'protobuf', 19 | 'websockets', 20 | 'aiohttp', 21 | ], 22 | classifiers=[ 23 | 'Development Status :: 5 - Production/Stable', 24 | 'Environment :: Console', 25 | 'Intended Audience :: Developers', 26 | 'License :: OSI Approved :: MIT License', 27 | 'Programming Language :: Python :: 3.7', 28 | 'Programming Language :: Python :: 3.8', 29 | 'Programming Language :: Python :: 3.9', 30 | ], 31 | ) 32 | --------------------------------------------------------------------------------