Maybe you should ask for it
It wasnt clear to me
-- LUA Script - precede every function and global member with lowercase name of script + '_main'
function soundloop_init(e)
end
function soundloop_main(e)
if GetPlayerDistance(e) <= 500 then
if g_Entity[e]['activated']==0 then
SetActivated(e,1)
LoopSound(e,0)
end
-- decrease volume if player goes away/ 100 is full volume (60 is very quiet in my opinion, so it just decrease to 66) then it stops the sound
-- Play with the 0.05 if it is to quiet / 0.06 is more quiet that 0.04
SetSoundVolume(100-(GetPlayerDistance(e)*0.05))
elseif GetPlayerDistance(e) > 500 then
StopSound(e,0)
SetActivated(e,0)
end
end
Maybe there is a better way, but this is the first I got how to achieve
Ebe Editor Free - Build your own EBE structures with easy and without editing any text files
Thread and Download