Merge branch 'dev' of http://git.legu.cc/liwei_3d/go_dreamfactory into dev
This commit is contained in:
commit
5fc2a0bb3f
@ -122,6 +122,7 @@ func (this *Dailytask) Reddot(session comm.IUserSession, rid ...comm.ReddotType)
|
||||
for _, v := range rid {
|
||||
switch v {
|
||||
case comm.Reddot25101:
|
||||
|
||||
for _, v := range dtask.Groups {
|
||||
if v.Complete {
|
||||
progress++
|
||||
@ -133,6 +134,9 @@ func (this *Dailytask) Reddot(session comm.IUserSession, rid ...comm.ReddotType)
|
||||
Progress: progress,
|
||||
Total: int32(len(dtask.Groups)),
|
||||
}
|
||||
if len(dtask.Groups) == 0 {
|
||||
reddot[comm.Reddot25101].Activated = false
|
||||
}
|
||||
break
|
||||
}
|
||||
}
|
||||
|
@ -101,8 +101,8 @@ func (this *GuildGve) Reddot(session comm.IUserSession, rid ...comm.ReddotType)
|
||||
for _, v := range rid {
|
||||
switch v {
|
||||
case comm.Reddot15301:
|
||||
reddot[comm.Reddot26101] = &pb.ReddotItem{
|
||||
Rid: int32(comm.Reddot26101),
|
||||
reddot[comm.Reddot15301] = &pb.ReddotItem{
|
||||
Rid: int32(comm.Reddot15301),
|
||||
Activated: true,
|
||||
Progress: member.Boosticket,
|
||||
}
|
||||
|
@ -14,7 +14,7 @@ func (this *apiComp) GetGymBuffCheck(session comm.IUserSession, req *pb.Practice
|
||||
return
|
||||
}
|
||||
|
||||
// /练功请求
|
||||
//练功请求
|
||||
func (this *apiComp) GetGymBuff(session comm.IUserSession, req *pb.PracticeGetGymBuffReq) (errdata *pb.ErrorData) {
|
||||
var (
|
||||
mryl *cfg.GamePandamasMrylData
|
||||
|
@ -13,7 +13,7 @@ func (this *apiComp) GymInfoCheck(session comm.IUserSession, req *pb.PracticeGym
|
||||
return
|
||||
}
|
||||
|
||||
// /获取每日一练信息
|
||||
//获取每日一练信息
|
||||
func (this *apiComp) GymInfo(session comm.IUserSession, req *pb.PracticeGymInfoReq) (errdata *pb.ErrorData) {
|
||||
var (
|
||||
err error
|
||||
|
@ -434,6 +434,7 @@ func (this *Practice) Reddot(session comm.IUserSession, rid ...comm.ReddotType)
|
||||
model *pandataModel
|
||||
room *pb.DBPracticeRoom
|
||||
pconf *cfg.GamePandamasMzData
|
||||
userex *pb.DBUserExpand
|
||||
usenum int32
|
||||
totalusenum int32
|
||||
err error
|
||||
@ -469,12 +470,22 @@ func (this *Practice) Reddot(session comm.IUserSession, rid ...comm.ReddotType)
|
||||
for _, v := range rid {
|
||||
switch v {
|
||||
case comm.Reddot26101:
|
||||
if userex, err = this.ModuleUser.GetUserExpand(session.GetUserId()); err != nil {
|
||||
this.Errorln(err)
|
||||
return
|
||||
}
|
||||
reddot[comm.Reddot26101] = &pb.ReddotItem{
|
||||
Rid: int32(comm.Reddot26101),
|
||||
Activated: true,
|
||||
Progress: room.Gymrefresh,
|
||||
Total: 1,
|
||||
}
|
||||
if userex.Globalbuff == 0 {
|
||||
reddot[comm.Reddot26101].Progress = 0
|
||||
} else {
|
||||
reddot[comm.Reddot26101].Progress = 1
|
||||
}
|
||||
|
||||
break
|
||||
case comm.Reddot26201:
|
||||
if totalusenum > 0 {
|
||||
|
@ -222,7 +222,7 @@ func (this *ModelUser) computeLevel(change *pb.UserResChangedPush) (lvchange boo
|
||||
curExp int64 = change.Exp
|
||||
res int64
|
||||
)
|
||||
|
||||
rewards = make([]*cfg.Gameatn, 0)
|
||||
for nextLvConf = this.module.configure.GetPlayerlvConf(curLv + 1); nextLvConf != nil; {
|
||||
if curExp >= int64(nextLvConf.Exp) {
|
||||
curExp = curExp - int64(nextLvConf.Exp)
|
||||
|
Loading…
Reference in New Issue
Block a user