修复playroom转盘bug

This commit is contained in:
hahwu 2025-07-23 16:53:37 +08:00
parent 18b0eb88b1
commit 56874ec22c

View File

@ -565,7 +565,10 @@ func (p *PlayroomMod) GetTaskReward(Type int) (int, []*item.Item, error) {
Id = GoUtil.RandMap(ProbList)
Items = playroomCfg.GetTaskJackpotReward(Id)
}
if len(Items) > 1 {
// 多个奖励时,随机选择一个
Items = []*item.Item{GoUtil.RandItem(Items)}
}
return Id, Items, nil
}