Skip to content

Add pet and partner HP and MP curves - #168

Merged
erwan-joly merged 1 commit into
masterfrom
claude/project-thread-wi9f5y-mate-vitality
Nov 12, 2026
Merged

erwan-joly merged 1 commit into
masterfrom
claude/project-thread-wi9f5y-mate-vitality

Conversation

@erwan-joly

@erwan-joly erwan-joly commented Nov 12, 2026 •

Copy link
Copy Markdown
Contributor

Part of NosCoreIO/NosCore#2826

Adds IMateHpService / MateHpService and IMateMpService / MateMpService. They give a pet's or partner's maximum HP and MP from:

  • its monster entry's race
  • its level
  • the growth factor from the entry's PETINFO line (first value for HP, third for MP)

The flat HP and MP from the entry's HP/MP line come on top.

Recorded pets match exactly:

Mate Race Factors (HP, MP) Level Recorded Curve
Partner 317 3 8, 6 28 2165 / 877 2165 / 877
Pet 2682 (+500 flat HP) 2 12, 0 48 10638 / 708 10638 / 708

The documentation test asserts both rows, and its approval table covers every race at factors 0, 4, 8 and 12. New feature, so this releases as 6.1.0.


Generated by Claude Code

Summary by CodeRabbit

  • New Features
    • Added calculations for mates’ maximum HP and MP based on race, level, and growth factor. Race-specific values are supported for races 0–6 and 8; flat HP and MP are not included.
  • Documentation
    • Added reference tables showing mate HP and MP values across selected races, levels, and growth factors.

A mate's maximum HP and MP follow its monster entry's race and growth
factors as it levels. Recorded pets at level 28 and 48 match the curve
exactly.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014gSmkVtYup7KTZ63CJcxZT
@coderabbitai

coderabbitai Bot commented Nov 12, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The change adds mate HP and MP calculation services. It also adds a shared effective-level helper and approval-test coverage that checks selected results and generates tables for races 0–6 and 8.

Changes

Mate HP and MP calculations

Layer / File(s) Summary
Mate HP and MP calculation services
src/NosCore.Algorithm/MateHpService/*, src/NosCore.Algorithm/MateMpService/*, test/NosCore.Algorithm.Tests/DocumentationTest.cs, documentation/DocumentationTest.MateHpMpDocumentation.approved.md
Adds HP and MP service interfaces and implementations. The calculations use race-specific values and effective levels. The approval test checks selected results and generates tables for the listed races, factors, and levels.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Feature

Suggested reviewers: claude

Merge Risk: Minimal · up to b6883

This change adds new mate HP and MP calculation services with documentation tests. No concrete merge-blocking risk was found; the recorded examples reportedly match the curves.

Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title "Add pet and partner HP and MP curves" matches the main change. The PR adds IMateHpService/MateHpService and IMateMpService/MateMpService, which calculate maximum HP and MP for pets and part…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title "Add pet and partner HP and MP curves" matches the main change. The PR adds IMateHpService/MateHpService and IMateMpService/MateMpService, which calculate maximum HP and MP for pets and partners from race, level, and growth factors. The title is specific and concise, and it names the primary change without file lists or vague terms.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 6353d8f and b6883fd.

Files selected for processing: 7

  • documentation/DocumentationTest.MateHpMpDocumentation.approved.md
  • src/NosCore.Algorithm/MateHpService/IMateHpService.cs
  • src/NosCore.Algorithm/MateHpService/MateHpService.cs
  • src/NosCore.Algorithm/MateHpService/MateLevel.cs
  • src/NosCore.Algorithm/MateMpService/IMateMpService.cs
  • src/NosCore.Algorithm/MateMpService/MateMpService.cs
  • test/NosCore.Algorithm.Tests/DocumentationTest.cs

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

@erwan-joly
erwan-joly merged commit 2660eea into master Nov 12, 2026
3 checks passed
@coderabbitai coderabbitai Bot mentioned this pull request Nov 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants