Health — Internal¶
Folder Overview¶
This folder contains internal helper utilities and evaluation logic used by the Health system.
These are not supported extension points and should be treated as implementation detail.
Purpose¶
This layer exists to support the runtime system with shared helpers and preview evaluation logic while keeping the public API surface clean.
What Lives Here¶
This folder may contain:
- Small helper utilities (combat, team lookup)
- Internal evaluation helpers (preview logic)
- Lightweight shared plumbing used across Health
It does not contain:
- Public contracts
- Supported extension seams
- Full system implementations
Components¶
CombatUtility¶
Helper for interacting with HealthCombatState (if present).
- Safe no-op if component is missing
-
Methods:
-
EnterOnOutgoingAttempt ForceEnterCombatTryExitCombat
Does not own combat state. Delegates to HealthCombatState.
TeamUtility¶
Resolves team ID via TeamProvider.
- Returns
TeamProvider.TeamIdif present - Otherwise returns
0(unknown or neutral)
This is a simple lookup, not a full team system.
HealthPreviewEvaluator¶
Internal helper for non-mutating previews.
Responsibilities:
- Computes damage and heal previews
- Applies rules (optionally)
- Uses shield preview when supported
- Applies healing modifiers
Behaviour:
- Does not mutate health, shields, or rules
- Uses
IShieldPreviewwhen available - Falls back safely when preview is not supported
Used by:
HealthSystem.PreviewDamage(...)HealthSystem.PreviewHeal(...)
This is a preview engine, not gameplay logic.
Important Notes¶
Boundaries¶
Do not:
- Depend on
.Internaltypes from gameplay code - Treat these as stable API
- Build systems on top of these helpers
- Assume behaviour here is fixed long-term
If similar functionality is needed, use:
- Public APIs (
HealthSystem) - Contracts (Abstractions)
- Rules, modifiers, or handlers
Usage Guidance¶
- Treat this folder as implementation detail
- Prefer public contracts and APIs for all integrations
- Expect internal helpers to change over time
Not for Production Use¶
This folder is not intended as a gameplay integration surface
Related Documentation¶
- Health System
- Abstractions
- Rules
- Handlers
- Components