private void createGameObject() { // Create a game object to handle playback _gameObject = new GameObject("SfxrGameObject-" + (Time.realtimeSinceStartup)); fixGameObjectParent(); // Create actual audio player _audioPlayer = _gameObject.AddComponent <SfxrAudioPlayer>(); _audioPlayer.SetSfxrSynth(this); }
private void createGameObject() { // Create a game object to handle playback _gameObject = new GameObject("SfxrGameObject-" + (Time.realtimeSinceStartup)); fixGameObjectParent(); // Create actual audio player _audioPlayer = _gameObject.AddComponent <SfxrAudioPlayer>(); _audioPlayer.SetSfxrSynth(this); _audioPlayer.SetRunningInEditMode(Application.isEditor && !Application.isPlaying); }
private void createGameObject() { // Create a game object to handle playback _gameObject = new GameObject("SfxrGameObject-" + (Time.realtimeSinceStartup)); fixGameObjectParent(); // Create actual audio player _audioPlayer = _gameObject.AddComponent<SfxrAudioPlayer>(); _audioPlayer.SetSfxrSynth(this); }
private void createGameObject() { // Create a game object to handle playback _gameObject = new GameObject("SfxrGameObject-" + (Time.realtimeSinceStartup)); fixGameObjectParent(); // Create actual audio player _audioPlayer = _gameObject.AddComponent<SfxrAudioPlayer>(); _audioPlayer.SetSfxrSynth(this); _audioPlayer.SetRunningInEditMode(Application.isEditor && !Application.isPlaying); }