Skip to content

fix: 修复血精石满充能后重置问题#151

Open
zombieJ wants to merge 1 commit into
masterfrom
codex-83k7go
Open

fix: 修复血精石满充能后重置问题#151
zombieJ wants to merge 1 commit into
masterfrom
codex-83k7go

Conversation

@zombieJ

@zombieJ zombieJ commented May 6, 2026

Copy link
Copy Markdown
Owner

血精石充能逻辑修复,旧神因子在白天结算时对血精石的充能改为读取当前次数并按上限截断后写回,避免已满状态继续叠加导致次数异常从而出现“满充能后重置”的问题;同时保留原有的溢出处理路径,确保将多余因子稳定转化到背包中的血精石,不会再因满值边界触发造成充能表现反复。


Codex Task

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 595acb2472

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +36 to +37
if currUses < maxUses then
finiteuses:SetUses(math.min(maxUses, currUses + factor))

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Clamp overcharged bloodstones back to max uses

When a bloodstone already has GetUses() >= total (e.g., save data created before this fix), this branch does nothing and leaves the invalid overcharged value in place. That is a regression from the previous logic, which always forced over-100% charge back to max via SetPercent(1), and it can let players keep unintended extra healing until the stone is consumed. Add a clamp path for currUses >= maxUses so existing abnormal stones are normalized.

Useful? React with 👍 / 👎.

Base automatically changed from next to master May 17, 2026 16:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant