Universal skills + Sanctum Ring, 2026-11-26 (Claude, owner-approved)
Owner ask: universal skills that fit EVERY weapon skill bar (melee, bow, staff), first one a "safe zone" (own name/look). Owner tuning: anyone inside attacking breaks the ring; long duration growing with rank (15 s -> 10 min); faster HP regen inside.
Rules (skill id 30, type "Universal", cast_mode "sanctum")
| Rank | Duration | Cooldown | Mana | HP regen inside |
|---|---|---|---|---|
| 1 | 15 s | 60 s | 30 | 2%/s max HP |
| 2 | 60 s | 120 s | 45 | 2% |
| 3 | 180 s | 300 s | 60 | 3% |
| 4 | 360 s | 600 s | 75 | 3% |
| 5 | 600 s | 900 s | 90 | 4% |
Unlock: Willpower 20 + Endurance 16 (tier 3 in SkillUnlockRules) + skill point. Ring: stationary at cast point, flattened ellipse radius 150 (SQUASH 0.62), one per caster (recast replaces). Enemies cannot damage players inside; enemy arrows break on the edge with a ripple; melee mobs wait at the edge (ranged may still shoot). Anyone inside committing an attack (needs a target) breaks it. Buffs/mining do not.
Files
- NEW
Scripts/Spells/SanctumRing.gd: ring node + static rules (spawn, ring_at, is_protected, break_for_attacker, contains, edge_point_toward), visual (_draw rim, runes, additive glow, light curtain, motes, ripples, warn blink, break fade), regen. SkillsList.gdregister_universal_active_skills (UNIVERSAL_ACTIVE_IDS [30], icon yellow_15).SkillUnlockRules.gd30: Willpower/Endurance tier 3.NativeSaveGuard.gdallows Skill30 investments.Skills.gd: Universal tab shows the bar panel + "Melee bar/Bow bar/Staff bar" picker; universal skills may sit on all three bars (one copy per bar); description shows duration/radius/regen.Player.gd: Universal compatible with every weapon; sanctum = no target, works unarmed, spawns ring; commit_native_action_cost breaks ring for targeted actions.GUI.gdbar compatibility;CombatService.apply_damage_to_playerguard (server rule);EnemyArrow.gdedge break;SkeletonEnemy.gdhold_at_sanctum_edge (melee).
Multiplayer
Ring = data (center, radius, ends_at, owner). Server keeps the list, runs the same contains/is_protected in CombatService and AI; protects ALL players inside; any player attacking from inside breaks it. Online code untouched (not built yet).
Evidence
Scripts/Build/VerifySanctumRing.gdisolated APPDATA: 33/33 PASS (test-results/sanctum_ring_20261126/report.json): data table, unlock, real Skills menu learn + three bars, one copy per bar, ellipse, damage blocked, regen, arrow breaks, one ring per owner, expiry, attack inside breaks, outside does not.- Rendered effect captures (isolated proof profile):
test-results/sanctum_ring_20261126/ring_*.png. - NOT checked: in-world play in MainWorld (MCP ports busy), real mob pathing at the edge, depth vs. props, cast animation per weapon, balance feel.
Rollback
Before copies: D:/WieldHavenBackups/archive/sanctum_ring_20261126/before/ (SHA256SUMS).
In-world test (owner asked to try it in the real game), same day
Probe D:/WieldHavenBackups/proof_recordings/perf_20261122/sanctum_shot.gd (rendered MainWorld, copy of owner saves slot 3, run via perf_20261122/run_wait.ps1 -Out sanctumN). Run sanctum9: learn via rules, cast from bow bar slot 1 (MP -30), 3 melee mobs aggroed -> 0 inside, waiting at ~180 px (edge 150); HP 136 -> 166 (regen, no damage); enemy arrow breaks on edge; player basic attack from inside breaks ring; Fire Arrow (slot 2) works afterwards. Fixed from the world test: mobs walked in after the PET (hold now for any non-enemy target); Sanctum card was cut off at the Universal tab edge (now own row "ANY WEAPON BAR"); bar picker buttons were off-screen (now "PUT ON BAR" buttons in the Universal tab); floor glow toned down; shorter description. Images: test-results/sanctum_ring_20261126/world/*.png. Verifiers after fixes: Sanctum 33/33, unlocks 41/41.
27.11 parandus
Cooldownid 120-900 s ei töötanud: Player.get_skill_cooldown_msec luges >60 millisekunditeks (Sanctum rank 2-5 cooldown oli 0,12-0,9 s). Nüüd <1000 = sekundid. Vt DARK_HOLE_PORTAL_20261127.md.