❤️ Health — Teaching Panels¶
The Teaching folder contains a set of lightweight IMGUI panels used for learning, debugging, and hands-on testing of the Health System directly inside your scenes.
These panels demonstrate how rules, shields, regeneration, combat state, and effects interact in real time.
Each panel is intentionally minimal and code-first — ideal for understanding behaviour, copying patterns, and wiring your own production UI later.
Status: Sample / Teaching UI — intended for development/testing scenes only. Not for shipping.
Define Guard:
REV_HEALTH_PRESENT⚠️ If a Teaching panel is present on a GameObject in a shipped scene, it will be visible and interactive at runtime.
Shipping with Teaching panels attached is a developer error, not a framework bug.
🧩 Panel Overview¶
| Panel | Focus | Notes |
|---|---|---|
| RulesBasicsTagPanel | Pre-rule damage flow | Armor, affinity, tags, preview vs applied damage |
| ShieldsPanel | Shield systems | Capacity, rechargeable, reduction, overheal, chaining |
| CritExecuteBuffsPanel | Post-rule flow | Crit chance, execute thresholds, attacker buffs |
| RegenIFramesCombatPanel | Reactive handlers | Regen, invincibility frames, combat state recovery |
| DotHotStacksPanel | Over-time effects | DOT/HOT stacks, tick timing, stacking semantics |
| TeamsFriendlyFirePanel | Team logic | Friendly fire rules and multipliers |
| DeathFxHandlersPanel | Death lifecycle | FX chain, slow-time, destruction hooks |
Each panel is self-contained and demonstrates one clear concept.
All panels inherit from TeachablePanelBase, use pure IMGUI, anchor top-left, and toggle with the Backquote (`) key.
🎯 Learning Goals¶
Across all panels you’ll learn to:
- Preview and apply damage using engine-accurate calculations
- Understand rule ordering (pre-rule vs post-rule evaluation)
- Configure and test shield behaviours and chains
- Observe critical hits, execute rules, and buffs
- Manage regeneration, invincibility frames, and combat state
- Apply and inspect DOT/HOT effects and stack logic
- Test team rules and friendly-fire scaling
- Inspect death handling and effect pipelines
💡 Example: Damage Preview vs Apply¶
Teaching panels demonstrate the same call patterns your production code will use:
var preview = health.PreviewDamage(ctx);
if (preview.WillApply)
{
var result = health.ApplyDamage(ctx);
}
No mock logic.
No demo-only shortcuts.
These panels show exactly what the runtime systems calculate.
🧰 Integration Tips¶
- Teaching panels are IMGUI-based and intended for Editor use only.
- They are excluded from player builds unless explicitly enabled and left in a scene.
- Safe to keep in dev scenes — they won’t affect runtime systems.
- Copy service calls, result handling, and rule configuration into your own UI.
- Ignore IMGUI/layout code — it’s scaffolding only.
Panels will clearly warn if required references or rules are missing.
🧱 Teaching Folder Layout¶
Health/
├─ Teaching/
│ ├─ RulesBasicsTagPanel.cs
│ ├─ ShieldsPanel.cs
│ ├─ CritExecuteBuffsPanel.cs
│ ├─ RegenIFramesCombatPanel.cs
│ ├─ DotHotStacksPanel.cs
│ ├─ TeamsFriendlyFirePanel.cs
│ └─ DeathFxHandlersPanel.cs
🧠 Quick Review¶
| Attribute | Summary |
|---|---|
| Audience | Developers integrating or exploring the Health system |
| Goal | Teach rule flow, effects, and combat behaviour |
| Style | Code-first, readable, and dependency-light |
| Location | Assets/RevFramework/Runtime/Systems/Health/Teaching/ |
| Safety | Editor-focused; must not be shipped with scenes |
| Theme | IMGUI — consistent with all RevFramework teaching panels |
TL;DR¶
The Teaching folder is your in-engine classroom for the Health system.
Use it to explore damage rules, shields, effects, and death handling — then copy the patterns into your own UI.