feat(gameserver): server-paced incantation FSM (slice 2a, #36) #75
No reviewers
Labels
No labels
alpha:wave-0
alpha:wave-1
alpha:wave-2
alpha:wave-3
area:assets
area:combat
area:ecology
area:infra
area:render
area:scripting
area:ui
area:world
enhancement
epic
migration
post-alpha
roadmap
tech-debt
type:bug
type:chore
type:design
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
marco/IsoMmo!75
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/incantation-fsm"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The core of the spell system (slice 2a of #36): you speak a spell word by word, the server paces emission, and the words appear overhead — the public tell. A modified client can't rush the sequence (server-driven), so the tell + anti-bot property always hold.
Server-side only for now — the client still casts via the instant
Castpath; migrating it to the paced words (input + overhead render) is the next PR.What lands
PowerWord(Xen/Ghy elements, Vur/Kor/Ren forms, Lop cancel) + aQueueWordintent + aPowerWordSpokenbroadcast (AoI, not the chat path).SpellSystemgains a per-caster incantation FSM:QueueWordsets the next word (element first, then a form; Lop cancels; a form-first / second-element is rejected with a catalog cue).Step(run each tick) emits a due word (~0.75s pacing viaEmitIntervalTicks), charges mana per word (no refund; free for a GM), surfaces it as aSpokenWord, and on a completed element+form resolves the bolt (LOS+range revalidated → fizzle; reuses the shared damage path). No next word within ~2s (QueueTimeoutTicks) resets it.SpokenWords+ resolutions throughTickResult;WorldTickbroadcastsPowerWordSpokenin AoI and the bolt/cues like the request path did.SystemMessageId: SpeakElementFirst, SpeakFormNext, IncantationCancelled, IncantationFaded) — per the rule.Verification
just lint→ 0 warnings.just test→ full suite green (GameServer 153, +8 incantation tests): two-word bolt emits both words then lands; form-first / second-element rejected; Lop cancels; timeout resets; mana charged per word; out-of-mana mid-cast resets; free cast spends nothing.Definition of Done (delta)
Next: 2a-client (word keybinds + overhead tell, remove the instant Cast), then 2b (shield/heal + invalid-combo).