This commit is contained in:
aozhiwei 2022-01-04 19:45:53 +08:00
parent 0ed0793757
commit f8d29ae26d
3 changed files with 67 additions and 0 deletions

22
doc/Chip.py Normal file
View File

@ -0,0 +1,22 @@
# -*- coding: utf-8 -*-
import _common
class Chip(object):
def __init__(self):
self.apis = [
{
'name': 'chipList',
'desc': '获取芯片列表',
'group': 'Gun',
'url': 'webapp/index.php?c=Gun&a=chipList',
'params': [
_common.ReqHead(),
],
'response': [
_common.RspHead(),
['!chip_list', [_common.Gun()], '芯片列表']
]
},
]

View File

@ -46,4 +46,17 @@ class Gun(object):
['property_chg', _common.PropertyChg(), '属性变更'], ['property_chg', _common.PropertyChg(), '属性变更'],
] ]
}, },
{
'name': 'gunList',
'desc': '获取枪械列表',
'group': 'Gun',
'url': 'webapp/index.php?c=Gun&a=gunList',
'params': [
_common.ReqHead(),
],
'response': [
_common.RspHead(),
['!gun_list', [_common.Gun()], '枪械列表']
]
},
] ]

View File

@ -24,6 +24,22 @@ class Attr(object):
['attr_val', 0, '属性值'], ['attr_val', 0, '属性值'],
] ]
class Gun(object):
def __init__(self):
self.fields = [
['gun_uniid', 0, '枪唯一id'],
['gun_id', 0, '枪id'],
['state', 0, '0已购买 1体验中'],
['gun_lv', 0, '枪等级'],
['quality', 0, '品阶'],
['!attr', [Attr()], '属性'],
['try_count', 0, '剩余体验次数 当state=1时才有意义'],
['lock_type', 0, '0:无锁 1:升级 2:升阶'],
['lock_time', 0, '使用锁定时间(升级或者升阶触发),单位秒,锁定期间不可战斗和做其他操作'],
['trade_locktime', 0, '出售锁定时间(升级或者升阶完成后触发),单位秒,只锁交易,其他的操作仍可进行'],
]
class GunSkin(object): class GunSkin(object):
def __init__(self): def __init__(self):
@ -349,3 +365,19 @@ class TeamInfo(object):
['state', 0, '0:未开始 1:准备就绪(这时客户端进入长链接走组队逻辑)'], ['state', 0, '0:未开始 1:准备就绪(这时客户端进入长链接走组队逻辑)'],
['!member_list', [TeamMember()], '队伍成员列表(包含自己)'], ['!member_list', [TeamMember()], '队伍成员列表(包含自己)'],
] ]
class Chip(object):
def __init__(self):
self.fields = [
['chip_uniid', 0, '芯片唯一id'],
['chip_id', 0, '芯片id'],
['state', 0, '0已购买 1体验中'],
['gun_lv', 0, '枪等级'],
['quality', 0, '品阶'],
['!attr', [Attr()], '属性'],
['try_count', 0, '剩余体验次数 当state=1时才有意义'],
['lock_type', 0, '0:无锁 1:升级 2:升阶'],
['lock_time', 0, '使用锁定时间(升级或者升阶触发),单位秒,锁定期间不可战斗和做其他操作'],
['trade_locktime', 0, '出售锁定时间(升级或者升阶完成后触发),单位秒,只锁交易,其他的操作仍可进行'],
]