import { decompressSector, COMPRESSION_ADPCM_MONO } from '../src/mpq/decompress.js'; import { AudioManager } from '../src/audio/manager.js'; async function run() { console.log("Verifying Audio dependencies..."); const manager = new AudioManager(); manager.setMasterVolume(1.0); console.log("AudioManager instantitated successfully."); try { const dummyInput = new Uint8Array([COMPRESSION_ADPCM_MONO, 0xFF]); // Just checking whether it acts properly (should throw ADPCM error on truncated data) await decompressSector(dummyInput, 100); } catch(err: any) { if (!err.message.includes('adpcm mono failed')) { console.error("decompressSector failed with wrong error: ", err); process.exit(1); } } console.log("Audio pipeline verification complete."); process.exit(0); } run().catch(err => { console.error(err); process.exit(1); });