PlaySettings

Sansar.Simulation.PlaySettings

PlaySettings Struct

The PlaySettings class contains settings for playing sounds.

Syntax

[Sansar.Script.Interface]
public struct PlaySettings

Remarks

Requirements

Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0

Members

See Also: Inherited members from ValueType.

Public Fields

  DontSync bool . false = we adjust the offset per Agent so that the sound is synchronized to everyone. This means late-joining Agents will hear sound at a greater offset. true = turn this off, let everyone hear sound from start / your offset
static readonly
Looped PlaySettings . The default play parameters for looped sounds.
  Looping bool . false = play once, true = sound will loop.
  Loudness float . Loudness in dB.
  Offset float . Play from time offset (in seconds). Use DontSync if you want everyone to hear the sound from this offset regardless of when they join.
  PitchShift float . Relative pitch, in semitones. Changing a sound's pitch also affects its duration. For example, if you raise the pitch by 12 semitones (an octave), it plays twice as quickly.
static readonly
PlayOnce PlaySettings . The default play parameters for sounds that play once.

Member Details

DontSync Field

false = we adjust the offset per Agent so that the sound is synchronized to everyone. This means late-joining Agents will hear sound at a greater offset. true = turn this off, let everyone hear sound from start / your offset

Syntax

[Sansar.Script.Interface]
public bool DontSync

Remarks

The default value is false.

Requirements

Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0

Looped Field

The default play parameters for looped sounds.

Syntax

[Sansar.Script.Interface]
public static readonly PlaySettings Looped

Remarks

 

Requirements

Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0

Looping Field

false = play once, true = sound will loop.

Syntax

[Sansar.Script.Interface]
public bool Looping

Remarks

The default value is false.

Requirements

Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0

Loudness Field

Loudness in dB.

Syntax

[Sansar.Script.Interface]
public float Loudness

Remarks

Default is 0.

Requirements

Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0

Offset Field

Play from time offset (in seconds). Use DontSync if you want everyone to hear the sound from this offset regardless of when they join.

Syntax

[Sansar.Script.Interface]
public float Offset

Remarks

The default is 0.

Requirements

Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0

PitchShift Field

Relative pitch, in semitones. Changing a sound's pitch also affects its duration. For example, if you raise the pitch by 12 semitones (an octave), it plays twice as quickly.

Syntax

[Sansar.Script.Interface]
public float PitchShift

Remarks

The default is 0.

Requirements

Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0

PlayOnce Field

The default play parameters for sounds that play once.

Syntax

[Sansar.Script.Interface]
public static readonly PlaySettings PlayOnce

Remarks

 

Requirements

Namespace: Sansar.Simulation
Assembly: Sansar.Simulation (in Sansar.Simulation.dll)
Assembly Versions: 1.1.0.0


Was this article helpful?
1 out of 1 found this helpful
Have more questions? Submit a request

0 Comments

Article is closed for comments.