This commit is contained in:
liwei1dao 2023-08-15 18:16:26 +08:00
commit 6026f8fed7

View File

@ -920,6 +920,13 @@ func (this *User) BingoSetUserLv(session comm.IUserSession, lv int32) error {
if lv <= 0 {
return comm.NewCustomError(pb.ErrorCode_ReqParameterError)
}
if conf := this.configure.GetPlayerlvConfList(); len(conf) > 0 {
maxlv := conf[len(this.configure.GetPlayerlvConfList())-1].Lv
if lv > maxlv {
lv = maxlv
}
}
update := map[string]interface{}{
"lv": lv,
"exp": 0,