Merge branch 'bs_2.0.6.28' of http://git.legu.cc/liwei_3d/go_dreamfactory into bs_2.0.6.28
This commit is contained in:
commit
8a21c0e476
@ -89,11 +89,13 @@ func (this *apiComp) Addblack(session comm.IUserSession, req *pb.FriendAddBlackR
|
||||
|
||||
// 将目标从好友列表中移除
|
||||
friendIds := utils.Deletex(self.FriendIds, req.FriendId)
|
||||
|
||||
// 将好友从申请列表移除
|
||||
applyIds := utils.Deletex(self.ApplyIds, req.FriendId)
|
||||
//更新
|
||||
err = this.module.modelFriend.Change(self.Uid, map[string]interface{}{
|
||||
"blackIds": self.BlackIds,
|
||||
"friendIds": friendIds,
|
||||
"applyIds": applyIds,
|
||||
})
|
||||
if err != nil {
|
||||
errdata = &pb.ErrorData{
|
||||
|
@ -109,6 +109,7 @@ func (this *apiComp) Agree(session comm.IUserSession, req *pb.FriendAgreeReq) (e
|
||||
}
|
||||
if err = this.module.modelFriend.Change(target.Uid, map[string]interface{}{
|
||||
"friendIds": target.FriendIds,
|
||||
"applyIds": target.ApplyIds,
|
||||
}); err != nil {
|
||||
errdata = &pb.ErrorData{
|
||||
Code: pb.ErrorCode_DBError,
|
||||
|
@ -94,8 +94,8 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.HuntingCha
|
||||
key := strconv.Itoa(int(req.BossType)) + "_" + strconv.Itoa(int(req.Difficulty))
|
||||
if hunting.BossTime[key] == 0 { // 新关卡挑战通过 发放首通奖励
|
||||
|
||||
hunting.BossTime[key] = req.Report.Costtime
|
||||
mapData["bossTime"] = hunting.BossTime
|
||||
//hunting.BossTime[key] = req.Report.Costtime
|
||||
//mapData["bossTime"] = hunting.BossTime
|
||||
if errdata = this.module.DispenseRes(session, cfgHunting.Firstprize, true); errdata != nil {
|
||||
return
|
||||
}
|
||||
@ -108,7 +108,7 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.HuntingCha
|
||||
}
|
||||
}
|
||||
// 耗时校验 当前战斗胜利时间消耗小于之前刷新数据
|
||||
if hunting.BossTime[key] > req.Report.Costtime {
|
||||
if hunting.BossTime[key] == 0 || hunting.BossTime[key] > req.Report.Costtime {
|
||||
hunting.BossTime[key] = req.Report.Costtime
|
||||
mapData["bossTime"] = hunting.BossTime // 更新时间
|
||||
this.module.CheckRank(session.GetUserId(), req.BossType, req.Difficulty, req.Report)
|
||||
|
@ -97,14 +97,14 @@ func (this *apiComp) ChallengeOver(session comm.IUserSession, req *pb.VikingChal
|
||||
|
||||
key := strconv.Itoa(int(req.BossId)) + "_" + strconv.Itoa(int(req.Difficulty))
|
||||
if viking.BossTime[key] == 0 { // 新关卡挑战通过 发放首通奖励
|
||||
viking.BossTime[key] = req.Report.Costtime
|
||||
mapData["bossTime"] = viking.BossTime // 更新时间
|
||||
//viking.BossTime[key] = req.Report.Costtime
|
||||
//mapData["bossTime"] = viking.BossTime // 更新时间
|
||||
if errdata = this.module.DispenseRes(session, vikingCfg.Firstprize, true); errdata != nil {
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
if viking.BossTime[key] > req.Report.Costtime {
|
||||
if viking.BossTime[key] == 0 || viking.BossTime[key] > req.Report.Costtime {
|
||||
viking.BossTime[key] = req.Report.Costtime
|
||||
mapData["bossTime"] = viking.BossTime // 更新时间
|
||||
this.module.CheckRank(session.GetUserId(), req.BossId, req.Difficulty, req.Report)
|
||||
|
Loading…
Reference in New Issue
Block a user