Hi,
create EAX only once, not in a loop. this works:

Code:
function test2()
{
	var envEAXSoundSys = eax_create();
	while(me)
	{
		if(key_a)
		{
			var han = ent_playsound(me, pSound, 500);
			eax_set(envEAXSoundSys, FX_UNDERWATER);
			eax_attach(envEAXSoundSys, han);
			wait(-0.5);
		}
		
		wait(1);
	}
}