update
This commit is contained in:
parent
04975072bb
commit
a19e485d8d
@ -32,7 +32,6 @@ func (this *apiComp) ChallengeCycleOver(session comm.IUserSession, req *pb.Pagod
|
|||||||
res []*cfg.Gameatn
|
res []*cfg.Gameatn
|
||||||
changExp map[string]int32
|
changExp map[string]int32
|
||||||
costTime int32 // 耗时
|
costTime int32 // 耗时
|
||||||
new bool // 是否首次挑战
|
|
||||||
fresh bool // 刷新记录
|
fresh bool // 刷新记录
|
||||||
)
|
)
|
||||||
changExp = make(map[string]int32, 0)
|
changExp = make(map[string]int32, 0)
|
||||||
@ -116,7 +115,7 @@ func (this *apiComp) ChallengeCycleOver(session comm.IUserSession, req *pb.Pagod
|
|||||||
Leadpos: Leadpos,
|
Leadpos: Leadpos,
|
||||||
Line: szLine,
|
Line: szLine,
|
||||||
}
|
}
|
||||||
if new {
|
|
||||||
if conf.Floors == 1 { // 写数据
|
if conf.Floors == 1 { // 写数据
|
||||||
db := &pb.DBCyclePagodaRecord{
|
db := &pb.DBCyclePagodaRecord{
|
||||||
Id: primitive.NewObjectID().Hex(),
|
Id: primitive.NewObjectID().Hex(),
|
||||||
@ -136,9 +135,10 @@ func (this *apiComp) ChallengeCycleOver(session comm.IUserSession, req *pb.Pagod
|
|||||||
this.module.modelCyclePagoda.addCrossPagodaCycle(session.GetUserId(), db)
|
this.module.modelCyclePagoda.addCrossPagodaCycle(session.GetUserId(), db)
|
||||||
}
|
}
|
||||||
res = append(res, conf.KeyReward...) // 首通奖励
|
res = append(res, conf.KeyReward...) // 首通奖励
|
||||||
}
|
|
||||||
// 校验是否刷新记录
|
// 校验是否刷新记录
|
||||||
if fresh || new {
|
if fresh {
|
||||||
|
this.module.modelCyclePagoda.getCrossPagodaCycleList(session.GetUserId())
|
||||||
this.module.modelCyclePagoda.SetCyclePagodaRankList(score, session.GetUserId())
|
this.module.modelCyclePagoda.SetCyclePagodaRankList(score, session.GetUserId())
|
||||||
mapData["data"] = list.Data
|
mapData["data"] = list.Data
|
||||||
user, err := this.module.ModuleUser.GetUser(session.GetUserId())
|
user, err := this.module.ModuleUser.GetUser(session.GetUserId())
|
||||||
|
Loading…
Reference in New Issue
Block a user