HammeriteAudioPortalProperties

Audio. Inherits RefCounted

Authored acoustic values on a portal, stored on the face the aperture is punched from.

Portals are derived: the compiler works out where two rooms open into each other on every recompile, and a HammeritePortal object does not survive the next edit. So a portal's identity cannot live on the portal. It lives on the authored thing underneath - the coplanar HammeriteFace the aperture is cut from - which is stable across recompiles, moves with the brush when the room is nudged, and is duplicated along with it when the room is copied.

That identity is what makes a doorway addressable at runtime: a door entity carries a portal name and calls HammeriteAudioNodeGraph.set_portal_occlusion_by_name() as it swings, and the sound through that opening closes with it.

The NAME itself is core's, and asked of core: HammeritePortal.get_portal_name() and HammeritePortal.set_portal_name(), because an opening is one opening - the same window a door names for sound is the one navigation climbs through, and two addons each storing their own name for it would eventually disagree. This class used to forward to both, which was two supported spellings of one thing (#235). What is acoustic - how much a closed door attenuates, how occluded it stands - lives here.

An aperture is cut from a PAIR of coplanar faces, one in each room, and which of them the compiler calls "a" falls out of brush iteration order rather than anything an author can see - so reads go through HammeritePortal.get_face_property(), which checks both.

Namespace for the keys below. Owned by HammeritePortal - the key shape is shared with every other consumer of an opening, and there is only one of it.

Native since 2.0 (#269): its static NAMESPACE is get_namespace(), and its constants are static methods of the same names in lower case.

Methods

ReturnsMethod
floatdefault_max_attenuation_db() static
floatdefault_occlusion() static
floatget_max_attenuation_db(portal: HammeritePortal) static
StringNameget_namespace() static
floatget_occlusion(portal: HammeritePortal) static
boolset_max_attenuation_db(portal: HammeritePortal, db: float) static
boolset_occlusion(portal: HammeritePortal, value: float) static

Method descriptions

default_max_attenuation_db()

static func default_max_attenuation_db() -> float

Undocumented.

default_occlusion()

static func default_occlusion() -> float

Undocumented.

get_max_attenuation_db()

static func get_max_attenuation_db(portal: HammeritePortal) -> float

Undocumented.

get_namespace()

static func get_namespace() -> StringName

Undocumented.

get_occlusion()

static func get_occlusion(portal: HammeritePortal) -> float

Undocumented.

set_max_attenuation_db()

static func set_max_attenuation_db(portal: HammeritePortal, db: float) -> bool

Undocumented.

set_occlusion()

static func set_occlusion(portal: HammeritePortal, value: float) -> bool

Undocumented.

Hammerite 2.0 · built from 6d57ab2d, 2026-10-17