Modme Forums
Menu:

Sound Loop Problem

Game Modding | Call of Duty: Black Ops 3 | Scripting


ModmeBot:

Thread By: eDeK
When i "press F" in a trigger, i have a song playing, the problem is when i "die" or i "restart the game" the song still playing.

function music()
{
    while (1)
    {
    	player PlaySound( "song" );
    	wait 250;
    }     
}

song,,,custom\song.wav,,,UIN_MOD,,,,,,,,,0,0,95,95,0,900,1000,,,,,,,,,,,,,,,,2d,,,NONLOOPING,,,,,,,,,,,,,,,,,,,,,,,yes,,,,yes,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,


ModmeBot:

Reply By: Harry Bo21

eDeK
When i "press F" in a trigger, i have a song playing, the problem is when i "die" or i "restart the game" the song still playing. function music() { while (1) { player PlaySound( "song" ); wait 250; } } song,,,custom\song.wav,,,UIN_MOD,,,,,,,,,0,0,95,95,0,900,1000,,,,,,,,,,,,,,,,2d,,,NONLOOPING,,,,,,,,,,,,,,,,,,,,,,,yes,,,,yes,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,

coz nothing tells it to stop

also by "restart" i assume you mean /fast_restart - and this is exactly why you shouldnt be using fast_restart


ModmeBot:

Reply By: eDeK

Harry Bo21
eDeK When i "press F" in a trigger, i have a song playing, the problem is when i "die" or i "restart the game" the song still playing. function music() { while (1) { player PlaySound( "song" ); wait 250; } } song,,,custom\song.wav,,,UIN_MOD,,,,,,,,,0,0,95,95,0,900,1000,,,,,,,,,,,,,,,,2d,,,NONLOOPING,,,,,,,,,,,,,,,,,,,,,,,yes,,,,yes,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, coz nothing tells it to stop also by "restart" i assume you mean /fast_restart - and this is exactly why you shouldnt be using fast_restart

Ok, thanks.


ModmeBot:

Reply By: TCM
Just do

/map_restart

takes a few seconds longer but seems to reset sounds etc.


ModmeBot:

Reply By: Harry Bo21
not gonna solve the "not stopping when i die" thing