Skip to content

💥 ScoreToMaxHealthを破壊 & ModifierAPIの最大体力のupdate_bonus以外を削除#2248

Merged
haiiro2gou merged 12 commits into
masterfrom
fix/lapis_max_health
May 16, 2026
Merged

💥 ScoreToMaxHealthを破壊 & ModifierAPIの最大体力のupdate_bonus以外を削除#2248
haiiro2gou merged 12 commits into
masterfrom
fix/lapis_max_health

Conversation

@Lapis-LJA

Copy link
Copy Markdown
Contributor

Fix #2246

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Fix #2246 by removing the legacy ScoreToMaxHealth/max-health ModifierAPI flow and switching max-health reads/updates to the vanilla attribute command path.

Changes:

  • Replaced api:modifier/max_health/get usages with attribute @s generic.max_health get across player/mob damage, regen, and health-percentage calculations.
  • Removed api:modifier/max_health/{add,get,remove} and related core functions; reworked max_health/update_bonus to apply an attribute modifier directly (via a new macro helper).
  • Disabled ScoreToMaxHealth-driven max-health modification in the ScoreToHealth datapack tick flow.

Reviewed changes

Copilot reviewed 21 out of 21 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
TheSkyBlessing/data/player_manager/functions/void_damage/damage.mcfunction Compute void damage from current generic.max_health attribute instead of API storage.
TheSkyBlessing/data/player_manager/functions/set_team_and_per_health.mcfunction Use attribute-based max health for team assignment / PerHealth computation.
TheSkyBlessing/data/player_manager/functions/health/regen/do.mcfunction Regen scaling now reads max health directly from attributes.
TheSkyBlessing/data/player_manager/functions/fall_damage/deal_damage/get_vars.mcfunction Fall-damage variables now pull max health from attributes.
TheSkyBlessing/data/mob_manager/functions/processing_tag/common_tag/anti_void_action/damage.mcfunction Mob anti-void damage scaling now uses attributes.
TheSkyBlessing/data/lib/functions/score_to_health_wrapper/proc.mcfunction Wrapper now reads max health from attributes.
TheSkyBlessing/data/debug/functions/modify_health/remove.mcfunction Debug remove now directly removes an attribute modifier by UUID.
TheSkyBlessing/data/debug/functions/modify_health/add.m.mcfunction Debug add now directly adds an attribute modifier via macro arg.
TheSkyBlessing/data/core/functions/handler/respawn.mcfunction Respawn “heal to 50% max” now uses attribute-based max health.
TheSkyBlessing/data/core/functions/handler/first_join.mcfunction Initializes player max health via attribute base set; removes MaxHealth from stored defaults.
TheSkyBlessing/data/asset_manager/functions/artifact/create/set_lore/modifier/.mcfunction Removes custom lore handling for Type:"max_health".
TheSkyBlessing/data/api/functions/modifier/max_health/update_bonus.mcfunction Reworks bonus max-health update to use attribute modifiers directly.
TheSkyBlessing/data/api/functions/modifier/max_health/remove.mcfunction Deleted legacy API remove entrypoint.
TheSkyBlessing/data/api/functions/modifier/max_health/get.mcfunction Deleted legacy API get entrypoint.
TheSkyBlessing/data/api/functions/modifier/max_health/add.mcfunction Deleted legacy API add entrypoint.
TheSkyBlessing/data/api/functions/modifier/core/max_health/remove.mcfunction Deleted legacy core remove implementation (storage-based).
TheSkyBlessing/data/api/functions/modifier/core/max_health/add.mcfunction Deleted legacy core add implementation (storage-based).
TheSkyBlessing/data/api/functions/modifier/core/max_health/add.m.mcfunction New macro helper to apply the BonusHealth attribute modifier.
TheSkyBlessing/data/api/functions/entity/player/get_health_per.mcfunction Health percentage now uses attribute-based max health.
ScoreToHealth/data/score_to_health/functions/player_tick.mcfunction Comments out ScoreToMaxHealth synchronization/modify step.
ScoreToHealth/data/score_to_health/functions/check.mcfunction Uses attribute-based max health instead of removed API call.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread TheSkyBlessing/data/core/functions/handler/first_join.mcfunction Outdated
@haiiro2gou haiiro2gou added the ⛏️ minor このPRはパッチアップデートに含められないよ label Apr 15, 2026

@haiiro2gou haiiro2gou left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

MUST: ここまでやるなら StMH の処理を全部消してしまおう

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 23 out of 23 changed files in this pull request and generated no new comments.

@haiiro2gou

Copy link
Copy Markdown
Member

Blocked by ProjectTSB/Asset#1963

@haiiro2gou haiiro2gou merged commit 94a6480 into master May 16, 2026
2 checks passed
@haiiro2gou haiiro2gou deleted the fix/lapis_max_health branch May 16, 2026 19:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

⛏️ minor このPRはパッチアップデートに含められないよ

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ScoreToMaxHealthを破壊する

3 participants