logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Namespace Serenity.AudioPlayer.Infrastructure.Components

    Classes

    UnityAudioPortalComponent

    An opening of an Audio Room: a point, placed in the middle of a doorway or window, through which a sound behind the room's walls is heard. It belongs to the nearest Audio Room above it and counts as open while it is enabled on an active GameObject, so closing a door means disabling its portal. Moving the portal or any ancestor to another room moves it at once; an Audio Room added above an enabled portal is picked up the next time the portal is enabled. A portal with no room above it tells the author once and keeps that warning even if it is parented under a room afterwards. The portal seam is implemented explicitly so the public surface stays unchanged.

    UnityAudioRoomComponent

    A room for the positioned depth cues: a space with openings (Audio Portals) through which a sound behind its walls is heard. The room announces itself to a registry while it is enabled and lists the portals that are open right now. Its shape is its first enabled trigger collider that can tell where a point lies, found when the room is enabled and when it starts. A room that has no shape, or whose shape is no longer usable (disabled, no longer a trigger, no longer able to answer), looks again when it is asked, at most once a frame, so a collider added or enabled later is seen on the next frame; a room whose shape is still usable never looks again until it is enabled; a collider destroyed while the room is enabled is replaced by the next supported trigger at once. A room that contains nothing, or has no portal under it, tells the author once when it starts. The room seam is implemented explicitly so the public surface stays unchanged.

    In this article
    © 2026 Serenity. All Rights Reserved