fix #417: world ambience kept playing at character select after the in-world logoff
The character-session reset manifest had no audio step: retail's logoff destroys the world's sound sources with the world, but our OpenAL world pool and ambient scheduler are process-lifetime — the continuous ambient beds played on at character select and the scheduler kept RE-FIRING deadlines against the stale listener (Suspend/StopAll had zero callers; WorldGenerationQuiescence only cycles around teleport-style generation replaces). New WorldAudioSessionGate: the reset manifest's 'world audio' step stops all sixteen world-pool voices (SuspendWorldAudio) and drops every ambient deadline (StopAll); the pool reopens at the entered-world edge through the new default-null LiveSessionEnteredWorldBindings.ResumeWorldAudio binding, invoked first in ApplyEnteredWorld. The ambient soundscape needs no explicit resume — the next objcell observation rebuilds it exactly as a cell change always did. Covers logout, reconnect, and full stop uniformly. UI-pool sounds (interface bank, portal cues) untouched by design. App tests 5568/3 skips, Runtime 1756/0. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
91c1962b0d
commit
0bb47f2711
8 changed files with 104 additions and 2 deletions
|
|
@ -30,7 +30,13 @@ public sealed record LiveSessionEnteredWorldBindings(
|
|||
Action RestoreLayout,
|
||||
Action SyncToolbar,
|
||||
Action<string> LoadCharacterSettings,
|
||||
Action ArmPlayerModeAutoEntry);
|
||||
Action ArmPlayerModeAutoEntry,
|
||||
/// <summary>Logout-audio round (2026-08-17): re-enables world-pool audio
|
||||
/// after the session reset's suspend (retail's logoff tears the world's
|
||||
/// sound sources down with the world; ours must re-open the pool at the
|
||||
/// next world entry). Default no-op preserves headless and existing
|
||||
/// construction sites.</summary>
|
||||
Action? ResumeWorldAudio = null);
|
||||
|
||||
public sealed record LiveSessionHostBindings(
|
||||
LiveSessionRoutingFactories Routing,
|
||||
|
|
@ -269,6 +275,11 @@ public sealed class LiveSessionHost
|
|||
private void ApplyEnteredWorld(LiveSessionCharacterSelection selection)
|
||||
{
|
||||
string name = selection.CharacterName;
|
||||
// FIRST: the world-audio pool must be open before any entered-world
|
||||
// callback can emit a sound (retail never closes its pool across a
|
||||
// logoff — the sources die with the world — so the reopened pool is
|
||||
// the earliest faithful moment).
|
||||
_enteredWorld.ResumeWorldAudio?.Invoke();
|
||||
_enteredWorld.SetActiveCharacter(name);
|
||||
_enteredWorld.RestoreLayout();
|
||||
_enteredWorld.SyncToolbar();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue