```
All checks were successful
ci/woodpecker/push/my-first-workflow Pipeline was successful

feat(service): 宠物添加功能增加销售计数参数并优化价格更新逻辑

- 修改PetAdd方法签名,增加salecount参数用于追踪宠物销售次数
- 在多个控制器中统一调用PetAdd方法时传入0作为初始销售次数
- 临时禁用寒流枪活动中的宠物发放功能
- 优化UPdatePrice方法,添加错误处理和价格范围验证逻辑
- 调整宠物购买逻辑,使用免费金币系统并计算递增购买
This commit is contained in:
昔念
2026-03-11 12:19:13 +08:00
parent 46bc05ab29
commit a29a8ddec2
17 changed files with 95 additions and 35 deletions

View File

@@ -86,7 +86,7 @@ func (h Controller) Collect(
r.Set(uint(data.Type))
te.Data = r.Bytes()
r := model.GenPetInfo(int(data.ID), -1, -1, 0, 1, nil, 0)
c.Service.Pet.PetAdd(r)
c.Service.Pet.PetAdd(r, 0)
result.CatchTime = r.CatchTime
return true