Sound Loop Problem! Need help Fast!
Moderator: Core Staff
Sound Loop Problem! Need help Fast!
I finished my map, and made a Music room!
Sound in it works, but it's not looping!
When i put "looping" under loop section in .csv, then i have no sound!
Also when i put PlayLoopSound in script, sound does not work, and with
PlayLocalSound it works but it does not loop!
Please help me, i want to fix that and release my map asap!
This is what i have in my .csv
name,sequence,file,vol_min,vol_max,vol_mod,pitch_min,pitch_max,dist_min,dist_max,channel,type,probability,loop,masterslave,loadspec,subtitle,compression,secondaryaliasname,volumefalloffcurve,startdelay,speakermap,reverb,lfe percentage,center percentage,platform,envelop_min,envelop_max,envelop percentage
#mapsounds,,,,,,,,,,,,,,,,,,,,,,,,,,,,
sound_1,1,music/finish.mp3,0.8,0.95,,0.95,1.05,7,1500,auto,streamed,,looping,,mp_eb_rudnik,,,,,,,,,,,,,
Sound in it works, but it's not looping!
When i put "looping" under loop section in .csv, then i have no sound!
Also when i put PlayLoopSound in script, sound does not work, and with
PlayLocalSound it works but it does not loop!
Please help me, i want to fix that and release my map asap!
This is what i have in my .csv
name,sequence,file,vol_min,vol_max,vol_mod,pitch_min,pitch_max,dist_min,dist_max,channel,type,probability,loop,masterslave,loadspec,subtitle,compression,secondaryaliasname,volumefalloffcurve,startdelay,speakermap,reverb,lfe percentage,center percentage,platform,envelop_min,envelop_max,envelop percentage
#mapsounds,,,,,,,,,,,,,,,,,,,,,,,,,,,,
sound_1,1,music/finish.mp3,0.8,0.95,,0.95,1.05,7,1500,auto,streamed,,looping,,mp_eb_rudnik,,,,,,,,,,,,,
-
- Core Staff
- Posts: 13313
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
Re: Sound Loop Problem! Need help Fast!
I have seen mentioned that mp3's have issues looping when not played at the correct bit rate.
It was a discussion in Rezil's last map release.
It was a discussion in Rezil's last map release.
Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
Re: Sound Loop Problem! Need help Fast!
ok. so i have to make .wav or can you tell me on what bitrate .mp3 would loop!?
-
- Core Staff
- Posts: 2030
- Joined: July 24th, 2006, 11:21 am
- Location: Cramped in a small cubicle/making another jump map
Re: Sound Loop Problem! Need help Fast!
Apparently it has to be 128kbps or it won't loop. Oddly enough even using 128kbps didn't help with my looping issue. I'd still just suggest you convert it to .wav, it will increase the file size but I think it shouldn't be that big of a problem for most people.
Drofder2004: Drofder's rules for reviewing a map
[...]
#5 If your name is Rezil, minimum 5/5.
---
<LT>YosemiteSam[NL]:
I heard somewhere that the best way to start is juggling 2 balls with one hand, so you will get a feel for it.
[...]
#5 If your name is Rezil, minimum 5/5.
---
<LT>YosemiteSam[NL]:
I heard somewhere that the best way to start is juggling 2 balls with one hand, so you will get a feel for it.
Re: Sound Loop Problem! Need help Fast!
it is 128 kbps! well ty, i will just convert it to .wav then!
thank you both for helping!
thank you both for helping!
Re: Sound Loop Problem! Need help Fast!
i made .wav now and tried it again, still nothing! -.-
this thing is gonna get me mad!
this thing is gonna get me mad!
Re: Sound Loop Problem! Need help Fast!
i saw ROTANT made on mp_kraftz on finish the music play only with this line of code, and it loops!
getent ("finish","targetname") playloopsound ("finish");
no other scripting besides that, and he uses .mp3
also if you leave the room, you can't hear the music!
i asked him how he done it but he cant remember cause he didn't map in a while!
kie also can't rememberhow to set looping!
so i know someone here knows how to do it with this! please help!
getent ("finish","targetname") playloopsound ("finish");
no other scripting besides that, and he uses .mp3
also if you leave the room, you can't hear the music!
i asked him how he done it but he cant remember cause he didn't map in a while!
kie also can't rememberhow to set looping!
so i know someone here knows how to do it with this! please help!
-
- Core Staff
- Posts: 13313
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
Re: Sound Loop Problem! Need help Fast!
Compare his mp3 bitrate to your own. Copy it exactly.
Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
Re: Sound Loop Problem! Need help Fast!
ok, i could do that, but the problem is that i have an other script, and i don't know how to do do it with this one ROTANT did!
getent ("finish","targetname") playloopsound ("finish");
what do i need to do in order to have only this line and to have my sound working and looping?
getent ("finish","targetname") playloopsound ("finish");
what do i need to do in order to have only this line and to have my sound working and looping?
-
- Core Staff
- Posts: 13313
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
Re: Sound Loop Problem! Need help Fast!
I cant see either your script of Rotants, so I do not know how either of you have done it. Post your script, there are plenty of scripters here.TrikX wrote:ok, i could do that, but the problem is that i have an other script, and i don't know how to do do it with this one ROTANT did!
getent ("finish","targetname") playloopsound ("finish");
what do i need to do in order to have only this line and to have my sound working and looping?
Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
Re: Sound Loop Problem! Need help Fast!
ok, so this is what i use, and music works, but with this script i cant get it to loop, not .mp3 or .wav
and this is all he has for the music part and it is in main() of the .gsc
i cant see his .csv cause he deleted it all from his computer!
but this is mine .csv
just to say, i tried with .wav and still nothing! so i have 128kbps .mp3 now
also, when i leave the trigger music stops what is supposed to do, but even when i shoot inside the room it stopped,
then i need to leave and enter again to start it!
so the best option for me would be to make a sound loop in 1 room and problem would be solved!
Code: Select all
trigger_init()
{
soundtriggers = getentarray( "sound_trigger", "targetname" );
for( i = 0; i < soundtriggers.size; i++ )
soundtriggers[i] thread trigger_sound();
}
trigger_sound()
{
soundpos = getent( self.target, "targetname" );
for(;;)
{
self waittill( "trigger", user );
if(!isDefined(user.sound) || user.sound != soundpos.script_noteworthy)
{
if(isDefined(user.sound))
user stoplocalsound(user.sound);
user.sound = soundpos.script_noteworthy;
user thread play_the_sound(soundpos.script_noteworthy);
user thread waitForLeave(self, soundpos.script_noteworthy);
}
wait 0.25;
}
}
play_the_sound( sound )
{
self endon("disconnect");
self notify("music_change");
self endon("music_change");
self playlocalsound( sound );
wait 500;
self.sound = undefined;
}
killSuspenseMusic()
{
wait 1;
if(isDefined(game) && isDefined(game["music"]) && isDefined(game["music"]["suspense"]))
for(i = 0;i < game["music"]["suspense"].size;i++)
game["music"]["suspense"][i] = "null";
}
waitForLeave(trigger, sound)
{
if(!isSubStr(sound, "1"))
return;
self endon("disconnect");
while(self isTouching(trigger))
wait 0.5;
self stopLocalSound(sound);
self.sound = undefined;;
}
and this is all he has for the music part and it is in main() of the .gsc
Code: Select all
getent ("finish","targetname") playloopsound ("finish");
but this is mine .csv
Code: Select all
name,sequence,file,vol_min,vol_max,vol_mod,pitch_min,pitch_max,dist_min,dist_max,channel,type,probability,loop,masterslave,loadspec,subtitle,compression,secondaryaliasname,volumefalloffcurve,startdelay,speakermap,reverb,lfe percentage,center percentage,platform,envelop_min,envelop_max,envelop percentage
#mapsounds,,,,,,,,,,,,,,,,,,,,,,,,,,,,
sound_1,1,music/finish.mp3,0.8,0.95,,0.95,1.05,7,1500,auto,streamed,,,,mp_eb_rudnik,,,,,,,,,,,,,
also, when i leave the trigger music stops what is supposed to do, but even when i shoot inside the room it stopped,
then i need to leave and enter again to start it!
so the best option for me would be to make a sound loop in 1 room and problem would be solved!
Re: Sound Loop Problem! Need help Fast!
i made now an other .mp3 file on 80kbps and that one loops!
but the problem now is that is playing on the whole map, and if i noclip trough any wall on map music stops and plays again! :O
how can i lower the radius or do i need to change something in .csv or my script?
but the problem now is that is playing on the whole map, and if i noclip trough any wall on map music stops and plays again! :O
how can i lower the radius or do i need to change something in .csv or my script?
-
- Core Staff
- Posts: 13313
- Joined: April 13th, 2005, 8:22 pm
- Location: UK, London
Re: Sound Loop Problem! Need help Fast!
dist_min,dist_max
Those two columns in your CSV are the distance to where you can hear sound and at what volume.
Those two columns in your CSV are the distance to where you can hear sound and at what volume.
Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010
Re: Sound Loop Problem! Need help Fast!
everything is fixed! it took me 3 days but it paid off!
by some miracle ROTANT found the .csv file and sent it to me!
now i have .mp3 file that loops ans plays as it should!
now i'm gonna put link of my new map mp_eb_rudnik on CJ so you all can play and see what i have done!
Again, thank you All for helping!
by some miracle ROTANT found the .csv file and sent it to me!
now i have .mp3 file that loops ans plays as it should!
now i'm gonna put link of my new map mp_eb_rudnik on CJ so you all can play and see what i have done!
Again, thank you All for helping!
-
- CJ G0D!
- Posts: 1575
- Joined: June 3rd, 2009, 9:02 pm
- Location: Cardiff University, UK
Re: Sound Loop Problem! Need help Fast!
It might be useful for others if you say how the ROTANT method works with that one line of script, so others can use it to help with their own problems, but I'm glad you got your problem fixed.
-
Who is online
Users browsing this forum: No registered users and 33 guests