format
typescript
AudioSource.loopclass: AudioSource
description
Whether the current audio is played in a loop.
If the audio source plays the audio in a loop, it returns true; otherwise, it returns false.
parameter
| param_name | type | description |
|---|
reture
| type | description |
|---|---|
boolean | Whether to loop the audio |
code example
typescript
let obj = new GameObject();
let source = obj.AddComponent<AudioSource>(AudioSource);
source.loop;