Skip to main content

Migration Guide - March 2026 Updates

This guide covers breaking changes and migration steps for updates released in March 2026.

Table of Contents

Player Death System (PR #1094)

Breaking Changes

1. PLAYER_DIED Event Deprecated

Status: DEPRECATED (March 26, 2026) Replacement: Use PLAYER_SET_DEAD for client death UI, or ENTITY_DEATH for server-side death processing. Migration:
Why: ENTITY_DEATH is a unified event for all entity types (players, mobs, NPCs), reducing event proliferation and improving consistency. Timeline: PLAYER_DIED is marked deprecated but still exists in the enum for backward compatibility. It will be removed in the next major version.

2. Death Lock Schema Change

Change: Death lock now includes keptItems field for crash recovery. Database Migration: Automatic (migration 0018 adds column with default NULL) Code Impact:
Action Required: None (backward compatible - old death locks have keptItems: null)

3. HeadstoneEntity Network Sync

Change: HeadstoneEntity.modify() now syncs lootItems from network data. Impact: Client-side gravestone entities now receive loot item updates, preventing stale item lists after looting. Code Impact:
Action Required: None (automatic via network sync)

New Features

OSRS Keep-3 System

Players now keep their 3 most valuable items on death in safe zones:
Value Source: Item values come from world/assets/manifests/items.json (value field) Stack Handling: Stacks are split intelligently - if you have 10,000 arrows and they’re in the top 3 most valuable, you keep 3 arrows and drop 9,997.

Death Utilities

New utility functions for death-related operations:

Troubleshooting

Player Stuck in Death Animation

Symptoms: Player plays death animation but never respawns. Diagnosis:
Recovery:
Prevention: Death system now has robust retry logic and crash recovery. If issues persist:
  1. Check server logs for DEATH_PERSIST_DESYNC tag
  2. Check for AUDIT_LOG events
  3. Verify database connection pool health

Equipment Duplication

Symptoms: Player has duplicate equipment after death. Root Cause: Fixed in PR #1094 - was caused by nested DB transactions deadlocking. Action: Update to latest version (March 26, 2026 or later).

Home Teleport System (PR #1095)

Breaking Changes

Cooldown Reduced

Change: Home teleport cooldown reduced from 15 minutes to 30 seconds. Constant Update:
Impact: Existing cooldown timers will complete at the old 15-minute duration. New teleports use 30-second cooldown. Action Required: None (automatic after server restart)

New Features

Server-Authoritative Cooldown

Server now sends remaining cooldown time in rejection packets:

Cooldown Formatting

New utility for human-readable cooldown display:

Cast Effects

New channel-mode portal effect with terrain-aware anchoring:
  • Dedicated cast-time portal (veil + orbital rings)
  • Grounded to player’s lowest bone position
  • Separate from arrival burst effect
  • Auto-stops on fail/cancel/completion
No Action Required: Effects are automatic when HOME_TELEPORT_CAST_START event fires.

Skilling Panel Components (PR #1093)

Breaking Changes

Shared Component Extraction

Change: Skilling panel styling and quantity selector extracted to shared components. Migration: If you have custom skilling panels, update to use shared components:
Benefits:
  • Eliminates ~500 lines of duplicated code
  • Consistent visual language across all skilling panels
  • Easier to maintain and update styling

New Features

Dialogue Character Portraits

Live 3D VRM portrait rendering in dialogue panels:
Features:
  • WebGPU viewport with live VRM rendering
  • Terrain-aware grounding
  • Automatic cleanup on unmount
  • Fallback to initials badge if model unavailable

Dialogue Popup Shell

Dedicated modal shell for NPC dialogue:
Features:
  • Proper focus management with focus trap
  • ARIA attributes for accessibility
  • Escape key handling
  • Backdrop click to close

Service Handoff Fix

Opening bank/store/tanner now properly closes dialogue:
Impact: No more orphaned dialogue panels when transitioning to service UIs.

UI Tab Arrow Keys (PR #1092)

Breaking Changes

reserveArrowKeys Prop

Change: TabBar component now accepts reserveArrowKeys prop to disable arrow key consumption. Migration:
When to Use:
  • Set reserveArrowKeys={true} for in-game panels (inventory, equipment, combat)
  • Set reserveArrowKeys={false} or omit for non-game UI (settings, character editor)
Impact: Arrow keys control camera movement even when panel tabs have focus. Enter/Space still activate tabs for keyboard accessibility.

Missing Packet Handlers (PR #1091)

New Handlers

Change: Added 8 missing server→client packet handlers to ClientNetwork.ts. Handlers Added:
  • onFletchingComplete - Fletching batch finished
  • onCookingComplete - Cooking result with burn check
  • onSmeltingComplete - Smelting batch finished
  • onSmithingComplete - Smithing batch finished
  • onCraftingComplete - Crafting batch finished
  • onTanningComplete - Tanning batch finished
  • onCombatEnded - Combat session ended
  • onQuestStarted - Quest begun notification
Migration: If you were handling these events manually, remove custom handlers:
Impact: Eliminates “No handler for packet” console errors.

Database Schema Changes

Death Lock Table

Migration 0018: Added kept_items column to death_locks table.
Action Required: None (automatic via Drizzle migrations) Rollback: If you need to rollback to pre-March-26 version:

Configuration Changes

Home Teleport Cooldown

File: packages/shared/src/constants/GameConstants.ts
Action Required: None (automatic after rebuild)

WebSocket Port

File: packages/client/.env
Action Required: Update .env file if you’re using custom WebSocket URL. Note: This change was from the March 19-20 performance overhaul (PR #1064), not March 26 updates.

Testing Updates

New Test Files

DeathUtils Tests (packages/shared/src/systems/shared/combat/__tests__/DeathUtils.test.ts):
  • 51 tests covering sanitization, stack splitting, position validation
  • Run: bunx vitest run packages/shared/src/systems/shared/combat/__tests__/DeathUtils.test.ts
PlayerDeathFlow Tests (packages/shared/src/systems/shared/combat/__tests__/PlayerDeathFlow.test.ts):
  • 10 tests covering death-to-respawn flow, guards, retry queue
  • Run: bunx vitest run packages/shared/src/systems/shared/combat/__tests__/PlayerDeathFlow.test.ts
Home Teleport Tests (packages/server/tests/unit/teleport/HomeTeleportManager.test.ts):
  • Updated tests for 30-second cooldown and remainingMs field
  • Run: bunx vitest run packages/server/tests/unit/teleport/HomeTeleportManager.test.ts

Deprecation Timeline

Immediate (March 26, 2026)

  • PLAYER_DIED event marked deprecated
  • All internal code migrated to ENTITY_DEATH

Next Major Version (TBD)

  • PLAYER_DIED event will be removed from EventType enum
  • External plugins must migrate before upgrading

Rollback Instructions

If you need to rollback to pre-March-26 state:

1. Revert Code Changes

2. Revert Database Schema

3. Clear Death Locks

4. Restart Services

Support

For issues or questions about these changes:
  1. Check GitHub Issues
  2. Review PR discussions:
  3. See CLAUDE.md for development guidelines