let spellStart = GetCurrentScriptDirectory ~ "se/se_cat00.wav";
let bossDeath = GetCurrentScriptDirectory ~ "se/se_enep01.wav";
let fireShot = GetCurrentScriptDirectory ~ "se/se_tan01.wav";
let drums = GetCurrentScriptDirectory ~ "se/Drums.wav";
let freedom = GetCurrentScriptDirectory ~ "se/Freedom.wav";
let musket1 = GetCurrentScriptDirectory ~ "se/Musket1.wav";
let musket2 = GetCurrentScriptDirectory ~ "se/Musket2.wav";
let laser = GetCurrentScriptDirectory ~ "se/se_lazer01.wav";
let timeout = GetCurrentScriptDirectory ~ "se/se_timeout.wav";
let timeout2 = GetCurrentScriptDirectory ~ "se/se_timeout2.wav";
let ice = GetCurrentScriptDirectory ~ "se/se_ice.wav";
let shing = GetCurrentScriptDirectory ~ "se/se_kira02.wav";
let charge = GetCurrentScriptDirectory ~ "se/se_ch00.wav";
let warpl = GetCurrentScriptDirectory ~ "se/se_warpl.wav";
let warpr = GetCurrentScriptDirectory ~ "se/se_warpr.wav";
let charge2 = GetCurrentScriptDirectory ~ "se/se_ch02.wav";
let fireShot2 = GetCurrentScriptDirectory ~ "se/se_tan02.wav";
let bulletBurst = GetCurrentScriptDirectory ~ "se/se_enep00.wav";
let Eff2 = GetCurrentScriptDirectory ~ "se/Eff2.wav";
let shot1 = GetCurrentScriptDirectory ~ "se/shot2.wav";
let groslaser = GetCurrentScriptDirectory ~ "se/se_nep00.wav";
let GetLife = GetCurrentScriptDirectory ~ "se/1UP.wav";

#include "./Functions.txt"

let sounds = [spellStart, bossDeath, fireShot, drums, freedom, musket1, musket2, laser, timeout, timeout2, ice, shing, charge, warpl, warpr, charge2, fireShot2, bulletBurst,Eff2,shot1,groslaser,GetLife];

task play(let id, let volume)   //id = line number - 1
{
	let obj = ObjSound_Create;
	ObjSound_Load(obj, sounds[id]);
	ObjSound_SetVolumeRate(obj, volume);
	ObjSound_Play(obj);
	
	RemoveSound(sounds[id]);
}

//plays timeout sfx for the given boss timer
task timer(time)
{
	wait((time - 10) * 60);
	loop (7) {
		play(8, 100);	//timeout 1
		wait(60);
	}
	loop (3) {
		play(9, 100);	//timeout 2
		wait(60);
	}
}



