コード例 #1
0
 public void Play(float volume = 1.0f, bool loop = false)
 {
     if (Source > 0)
     {
         AL.Source(Source, ALSourcef.Gain, volume);
         AL.Source(Source, ALSourceb.Looping, loop);
         AL.SourcePlay(Source);
     }
 }
コード例 #2
0
 public void Play(Vector3 pos, float volume = 1.0f, bool loop = false)
 {
     if (Source > 0)
     {
         AL.Source(Source, ALSource3f.Position, ref pos);
         AL.Source(Source, ALSourcef.Gain, volume);
         AL.Source(Source, ALSourceb.Looping, loop);
         AL.SourcePlay(Source);
     }
 }