Definition at line 3 of file ESoundSource.cs.
◆ OnDisable()
void ESoundSource.OnDisable |
( |
| ) |
|
|
inlineprivate |
◆ OnEnable()
void ESoundSource.OnEnable |
( |
| ) |
|
|
inlineprivate |
Definition at line 13 of file ESoundSource.cs.
14 {
16 InvokeRepeating("Refresh", 0f, 0.1f);
17 }
References Play().
◆ Play()
void ESoundSource.Play |
( |
| ) |
|
|
inline |
Definition at line 24 of file ESoundSource.cs.
25 {
26 source.clip =
data.clip;
27 source.loop = data.loop != 0;
28 source.volume =
data.volume;
29 source.pitch = data.pitch * (1f + ((data.randomPitch == 0f) ? 0f :
Rand.
Range(0f -
data.randomPitch,
data.randomPitch)));
30 source.time =
data.startAt;
31 source.name =
data.name;
32 source.spatialBlend = 0f;
34 }
static int Range(int min, int max)
References data, Rand.Range(), and source.
Referenced by OnEnable().
◆ Refresh()
void ESoundSource.Refresh |
( |
| ) |
|
|
inline |
◆ data
SoundData ESoundSource.data |
◆ maxDistance
float ESoundSource.maxDistance |
◆ owner
◆ source
AudioSource ESoundSource.source |
The documentation for this class was generated from the following file: