皮肤技能加成

This commit is contained in:
sk 2024-07-25 11:26:32 +08:00
parent f1a6cd7389
commit 22cc427ea5
2 changed files with 9 additions and 2 deletions

View File

@ -321,7 +321,11 @@ func (this *CSDiamondLotteryHandler) Process(s *netlib.Session, packetid int, da
}
random := rand.Intn(weight) + 1
value := 0
p.DiamondLotteryScore += 1
p.DiamondLotteryScore += 100
add := p.GetSkillAdd(common.SkillIdDiamondLottery)
if add > 0 {
p.DiamondLotteryScore += int64(add)
}
//判断是否白名单用户
whiteList := config.Players
status := false
@ -332,7 +336,7 @@ func (this *CSDiamondLotteryHandler) Process(s *netlib.Session, packetid int, da
break
}
}
if playerData != nil && p.DiamondLotteryScore%int64(playerData.Count) == 0 {
if playerData != nil && p.DiamondLotteryScore%int64(playerData.Count*100) == 0 {
status = true
}
if status {

View File

@ -219,6 +219,9 @@ func (this *WelfareMgr) UpdatePhoneLotteryStatus(cfg *webapi_proto.WelfarePhoneL
func (this *WelfareMgr) UpdateDiamondLotteryConfig(cfg *webapi_proto.DiamondLotteryConfig) {
info := this.GetConfig(cfg.Platform)
info.DiamondLotteryConfig = cfg
for _, v := range info.DiamondLotteryConfig.GetLotteryData() {
v.MaxScore *= 100
}
}
func (this *WelfareMgr) GetPhoneLotteryStatus(platform string) int32 {