DistanceAttenuationMode列挙型(Enum)
列挙型(Enum)日本語解説は準備中
ひとことで言うと
DistanceAttenuationModeは、ロブロックス(Roblox)の列挙型(Enum)です。くわしい日本語解説は準備中のため、下に公式の説明(英語)を載せています。
公式の説明(英語):Determines how an AudioEmitter attenuates (fades out) as the distance between the AudioEmitter and an interacting AudioListener increases.
選べる値(5)
| 名前 | 値 | 説明 |
|---|---|---|
Enum.DistanceAttenuationMode.Custom | 0 | Uses the developer-supplied Class.AudioEmitter.DistanceAttenuation|DistanceAttenuation curve for gain rolloff. |
Enum.DistanceAttenuationMode.InverseTapered | 1 | Volume attenuates according to a hybrid model which follows the DistanceAttenuationMode.Inverse model when close to the lower bound of AudioEmitter.DistanceAttenuationBounds and the DistanceAttenuationMode.LinearSquared model when close to the upper bound of AudioEmitter.DistanceAttenuationBounds. This is done by taking the lesser of these two curves, such that the curve mostly follows an inverse relationship but tapers to silence at the maximum distance. |
Enum.DistanceAttenuationMode.Linear | 2 | Volume attenuates between the bounds of AudioEmitter.DistanceAttenuationBounds with a linear relationship. This is done by computing (maxDistance - distance) / (maxDistance - minDistance), where distance is the Vector3.Magnitude between the AudioEmitter's position and the AudioListener's position. |
Enum.DistanceAttenuationMode.LinearSquared | 3 | Volume attenuates between the bounds of AudioEmitter.DistanceAttenuationBounds with a linear-squared relationship. This is done by squaring the formula used to determine the volume when using DistanceAttenuationMode.Linear, which creates a parabolic curve with a steeper fade. |
Enum.DistanceAttenuationMode.Inverse | 4 | Volume attenuates from the lower bound of AudioEmitter.DistanceAttenuationBounds in an inverse manner, mirroring how sounds attenuate in the real world. This is done by computing (minDistance/distance), where distance is the Vector2.Magnitude between the AudioEmitter's position and the AudioListener's position. |
英語の説明とメンバーの一覧は、Roblox Creator Documentation(DistanceAttenuationMode)をもとにしています(CC BY 4.0)。日本語の解説は、このサイトで独自に書いたものです。