[ARCH] Zone behavior scattered across 3 classes — introduce ZoneManager with events #16

Closed
opened 2026-03-12 00:03:05 +00:00 by lavarius · 0 comments
Owner

🟠 High — Architecture

Files: MovementManager.cs, AnimationController.cs, CharacterZoneChanger.cs

Zone change logic is scattered across three classes, each responding to zone changes independently via SendMessage. This creates duplicated state and tight implicit coupling.

Fix: Introduce a dedicated ZoneManager with a single C# event:

public static event Action<ZoneType> OnZoneChanged;

All interested classes subscribe/unsubscribe cleanly in OnEnable/OnDisable.

## 🟠 High — Architecture **Files:** `MovementManager.cs`, `AnimationController.cs`, `CharacterZoneChanger.cs` Zone change logic is scattered across three classes, each responding to zone changes independently via `SendMessage`. This creates duplicated state and tight implicit coupling. **Fix:** Introduce a dedicated `ZoneManager` with a single C# event: ```csharp public static event Action<ZoneType> OnZoneChanged; ``` All interested classes subscribe/unsubscribe cleanly in `OnEnable`/`OnDisable`.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
lavarius/ProjectOverlay#16
No description provided.