查询玩家基本信息
This commit is contained in:
parent
075c9b3c53
commit
ecd609ffc0
@ -92,3 +92,51 @@ exports.UserGroupMember = class {
|
|||||||
}
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
exports.Player = class {
|
||||||
|
constructor()
|
||||||
|
{
|
||||||
|
this.fields = [
|
||||||
|
['account_id', '', '用户id'],
|
||||||
|
['channel', '', '渠道id'],
|
||||||
|
['name', '', '用户名'],
|
||||||
|
['sex', 0, '性别'],
|
||||||
|
['head_id', 0, '头像id'],
|
||||||
|
['head_frame', 0, '头像框id'],
|
||||||
|
['level', 0, '等级'],
|
||||||
|
['exp', 0, '经验'],
|
||||||
|
['rank', 0, '段位'],
|
||||||
|
['history_best_rank', 0, '历史最高段位'],
|
||||||
|
['score', 0, '积分'],
|
||||||
|
['history_best_score', 0, '历史最高积分'],
|
||||||
|
['elo', 0, '隐藏elo积分'],
|
||||||
|
['bceg', 0, '治理代币'],
|
||||||
|
['gold', 0, '金币'],
|
||||||
|
['diamond', 0, '钻石'],
|
||||||
|
['hero_id', 0, '当前上阵英雄id'],
|
||||||
|
['first_fight', 0, '是否首战'],
|
||||||
|
['last_season_id', 0, '最后一次赛季id'],
|
||||||
|
['activated', 0, '是否已激活'],
|
||||||
|
['rename_count', 0, '改名次数'],
|
||||||
|
['activatetime', 0, '激活时间'],
|
||||||
|
['already_guide', 0, '已引导'],
|
||||||
|
['pve_instance_id', 0, '已过pve副本id'],
|
||||||
|
['like_count', 0, '被点赞次数'],
|
||||||
|
['head_list', '', '拥有的头像列表'],
|
||||||
|
['head_frame_list', '', '拥有的头像框列表'],
|
||||||
|
['consume_gold', 0, '消费金币数'],
|
||||||
|
['score_modifytime', 0, '积分修改时间'],
|
||||||
|
['best_rank_modifytime', 0, 'bestrank修改时间'],
|
||||||
|
['createtime', 0, '创建时间'],
|
||||||
|
['last_login_time', 0, '上次登录时间'],
|
||||||
|
['is_gain_item', 0, '是否获取免费item道具'],
|
||||||
|
['guild_id', '', '工会id'],
|
||||||
|
['guild_job', 0, '工会职位'],
|
||||||
|
['guild_name', '', '工会名称'],
|
||||||
|
['ring_id', 0, '戒指id'],
|
||||||
|
['parachute', 0, '降落伞id'],
|
||||||
|
['star_num', 0, '星星数(成长任务)'],
|
||||||
|
['address', '', '钱包地址'],
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@ -8,4 +8,5 @@ type ApiGroup struct {
|
|||||||
UserGroupApi
|
UserGroupApi
|
||||||
GroupMemberApi
|
GroupMemberApi
|
||||||
BattleServerApi
|
BattleServerApi
|
||||||
|
PlayerApi
|
||||||
}
|
}
|
||||||
|
@ -102,6 +102,15 @@ func (this *app) registerDataSources() {
|
|||||||
mt.Table.MailDb.GetById(0).GetDatabase(),
|
mt.Table.MailDb.GetById(0).GetDatabase(),
|
||||||
1,
|
1,
|
||||||
)
|
)
|
||||||
|
f5.GetGoStyleDb().RegisterDataSource(
|
||||||
|
constant.GAME_DB,
|
||||||
|
mt.Table.GameDb.GetById(0).GetHost(),
|
||||||
|
mt.Table.GameDb.GetById(0).GetPort(),
|
||||||
|
mt.Table.GameDb.GetById(0).GetUser(),
|
||||||
|
mt.Table.GameDb.GetById(0).GetPasswd(),
|
||||||
|
mt.Table.GameDb.GetById(0).GetDatabase(),
|
||||||
|
1,
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (this *app) AddSession(accountId string) string {
|
func (this *app) AddSession(accountId string) string {
|
||||||
|
@ -1,13 +1,34 @@
|
|||||||
package common
|
package common
|
||||||
|
|
||||||
|
import (
|
||||||
|
"f5"
|
||||||
|
"q5"
|
||||||
|
)
|
||||||
|
|
||||||
type Attachment struct {
|
type Attachment struct {
|
||||||
ItemId int32 `json:"itemid"`
|
ItemId int32 `json:"itemid"`
|
||||||
ItemNum int32 `json:"itemnum"`
|
ItemNum int32 `json:"itemnum"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type StreamPagination struct {
|
||||||
|
NextCursor string `json:"next_cursor"`
|
||||||
|
PreviousCursor string `json:"previous_cursor"`
|
||||||
|
Remaining int32 `json:"remaining"`
|
||||||
|
}
|
||||||
|
|
||||||
type App interface {
|
type App interface {
|
||||||
Run(func(), func())
|
Run(func(), func())
|
||||||
AddSession(accountId string) string
|
AddSession(accountId string) string
|
||||||
GetSessionAccountId(accountId string) string
|
GetSessionAccountId(accountId string) string
|
||||||
RemoveSession(accountId string)
|
RemoveSession(accountId string)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (this *StreamPagination) FillPage(page *f5.StreamPagination) {
|
||||||
|
if page.NextCursor != 0 {
|
||||||
|
this.NextCursor = q5.ToString(page.NextCursor)
|
||||||
|
}
|
||||||
|
if page.PreviousCursor != 0 {
|
||||||
|
this.PreviousCursor = q5.ToString(page.PreviousCursor)
|
||||||
|
}
|
||||||
|
this.Remaining = page.Remaining
|
||||||
|
}
|
||||||
|
@ -3,6 +3,7 @@ package router
|
|||||||
import (
|
import (
|
||||||
"f5"
|
"f5"
|
||||||
"main/middleware"
|
"main/middleware"
|
||||||
|
|
||||||
//. "main/global"
|
//. "main/global"
|
||||||
"main/router/system"
|
"main/router/system"
|
||||||
)
|
)
|
||||||
@ -23,6 +24,7 @@ func (this *routerMgr) Init() {
|
|||||||
this.system.InitUserGroupRouter(priGroup)
|
this.system.InitUserGroupRouter(priGroup)
|
||||||
this.system.InitGroupMemberRouter(priGroup)
|
this.system.InitGroupMemberRouter(priGroup)
|
||||||
this.system.InitBattleServerRouter(priGroup)
|
this.system.InitBattleServerRouter(priGroup)
|
||||||
|
this.system.InitPlayerRouter(priGroup)
|
||||||
f5.GetSysLog().Info("routerMgr.init")
|
f5.GetSysLog().Info("routerMgr.init")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -8,4 +8,5 @@ type RouterGroup struct {
|
|||||||
UserGroupRoute
|
UserGroupRoute
|
||||||
GroupMemberRoute
|
GroupMemberRoute
|
||||||
BattleServerRoute
|
BattleServerRoute
|
||||||
|
PlayerRouter
|
||||||
}
|
}
|
||||||
|
2
third_party/f5
vendored
2
third_party/f5
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 693a5ab7b0d3e7cadd206ebfd29a9df5fca3ea48
|
Subproject commit bf49efd5a029a9e0749019c03fb4295dd89bf350
|
2
third_party/q5
vendored
2
third_party/q5
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 8877d9e02aff92bdf726954501109ce474d51f25
|
Subproject commit 763b161e26e76046ee7614852ccdd4a360f15237
|
Loading…
x
Reference in New Issue
Block a user