Skip to content

Commit 3916eb4

Browse files
Docs: describe Hytale signal seam usage for arena events
1 parent a021aff commit 3916eb4

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# Hytale Adapter Signal Seam (Internal)
2+
3+
This document describes how platform-integrated modules should emit internal arena signals without adding Hytale imports or gameplay logic to LegendaryCore.
4+
5+
## Why this exists
6+
- LegendaryCore must remain platform-agnostic and signal-only.
7+
- Platform modules (with real Hytale imports) detect gameplay conditions and post internal events onto the CoreRuntime EventBus.
8+
9+
## Seam
10+
- `io.github.legendaryforge.legendary.core.internal.platform.hytale.HytaleSignalSource`
11+
- Bound via `new HytalePlatformAdapter(runtime, signalSource)`
12+
13+
## Arena bounds enforcement pipeline (current)
14+
1. Platform module detects a breach (player outside arena bounds for an encounter instance).
15+
2. Platform module posts:
16+
- `ArenaBoundsViolatedEvent.withoutPosition(instanceId, playerId)`
17+
3. Core `BoundsInvariant` (legendary-only, instance-gated) posts:
18+
- `ArenaParticipationRevokedEvent(instanceId, playerId)`
19+
4. Platform module reacts (behavior lives here):
20+
- move player to spectator / prevent actions / show UI warning / etc.
21+
22+
## Non-goals (explicit)
23+
- No teleporting or physics correction inside LegendaryCore.
24+
- No Hytale imports in LegendaryCore.
25+
- No public API changes for bounds enforcement.
26+
27+
## Minimum implementation notes for platform module
28+
- You will need a way to map `playerId -> encounter instanceId` (content/platform-owned).
29+
- You will need arena bounds data (content/platform-owned): center + radius (v1), or AABB later.
30+
- Emit violations on tick or movement updates; de-dupe or rate-limit in platform module if desired (Core already de-dupes revoke per player per instance).
31+

0 commit comments

Comments
 (0)