In my hlds when my plugin would take action, it would greet the player then play some music. For some reason, the music loops and keeps repeating when the .wav file is over. I was planning to make a /off command but i couldnt figure out a way to stop the music.
PHP Code:
public client_putinserver(id)
{
set_task(3.0, "Greet", TASK_GREET + id)
}
public Greet(id)
{
id -= TASK_GREET
ColorChat(id, GREEN, "^x03[^x04cBg^x03]^x01 Greetings^x01, Have fun and enjoy your stay at^x04 Cold Blooded Gaming^x01!");
ColorChat(id, GREEN, "^x03[^x04cBg^x03]^x01 Don't like the music? Turn it^x03 off^x01 by typeing^x04 /off^x01!");
ColorChat(id, GREEN, "^x03[^x04cBg^x03]^x01 Contact^x04 r4nDoMz^x01 if you encounter any^x03 problems^x01.");
client_cmd(id, "spk ambience/cbg.wav")
}
How do i stop the music from looping? How do i get the /off to take action?
__________________