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