ServerConfiguration/Calla/Calla-Lib/game/bundle.js
/**
     * If no audio context is currently available, creates one, and initializes the
     * spatialization of its listener.
     * 
     * If WebAudio isn't available, a mock audio context is created that provides
     * ersatz playback timing.
     **/
If no audio context is currently available, creates one, and initializes the
spatialization of its listener.

If WebAudio isn't available, a mock audio context is created that provides
ersatz playback timing.
If no audio context is currently available creates one and initializes the spatialization of its listener . If WebAudio isn ' t available a mock audio context is created that provides ersatz playback timing .
createContext() {
        if (!this.audioContext) {
            if (hasAudioContext$1) {
                try {
                    this.audioContext = new AudioContext();
                }
                catch (exp) {
                    hasAudioContext$1 = false;
                    console.warn("Could not create WebAudio AudioContext", exp);
                }
            }
            if (!hasAudioContext$1) {
                this.audioContext = new MockAudioContext();
            }
            if (hasAudioContext$1 && attemptResonanceAPI) {
                try {
                    this.listener = new ResonanceScene(this.audioContext);
                }
                catch (exp) {
                    attemptResonanceAPI = false;
                    console.warn("Resonance Audio API not available!", exp);
                }
            }
            if (hasAudioContext$1 && !attemptResonanceAPI && hasNewAudioListener) {
                try {
                    this.listener = new AudioListenerNew(this.audioContext.listener);
                }
                catch (exp) {
                    hasNewAudioListener = false;
                    console.warn("No AudioListener.positionX property!", exp);
                }
            }
            if (hasAudioContext$1 && !attemptResonanceAPI && !hasNewAudioListener && hasOldAudioListener) {
                try {
                    this.listener = new AudioListenerOld(this.audioContext.listener);
                }
                catch (exp) {
                    hasOldAudioListener = false;
                    console.warn("No WebAudio API!", exp);
                }
            }
            if (!hasOldAudioListener || !hasAudioContext$1) {
                this.listener = new BaseListener();
            }
            this.pose.spatializer = this.listener;
        }
    }
createContext ( ) { if ( ! this . audioContext ) { if ( hasAudioContext$1 ) { try { this . audioContext = new AudioContext ( ) ; } catch ( exp ) { hasAudioContext$1 = false ; console . warn ( "Could not create WebAudio AudioContext" , exp ) ; } } if ( ! hasAudioContext$1 ) { this . audioContext = new MockAudioContext ( ) ; } if ( hasAudioContext$1 && attemptResonanceAPI ) { try { this . listener = new ResonanceScene ( this . audioContext ) ; } catch ( exp ) { attemptResonanceAPI = false ; console . warn ( "Resonance Audio API not available!" , exp ) ; } } if ( hasAudioContext$1 && ! attemptResonanceAPI && hasNewAudioListener ) { try { this . listener = new AudioListenerNew ( this . audioContext . listener ) ; } catch ( exp ) { hasNewAudioListener = false ; console . warn ( "No AudioListener.positionX property!" , exp ) ; } } if ( hasAudioContext$1 && ! attemptResonanceAPI && ! hasNewAudioListener && hasOldAudioListener ) { try { this . listener = new AudioListenerOld ( this . audioContext . listener ) ; } catch ( exp ) { hasOldAudioListener = false ; console . warn ( "No WebAudio API!" , exp ) ; } } if ( ! hasOldAudioListener || ! hasAudioContext$1 ) { this . listener = new BaseListener ( ) ; } this . pose . spatializer = this . listener ; } }
If no audio context is currently available, creates one, and initializes the
 spatialization of its listener.
If no audio context is currently available creates one and initializes the spatialization of its listener .