Hmm well with the script below the sound goes out about 40 seconds-90 seconds into the song.
This is a test script Chris Vimes used to attempt to try resolve the problem:
PHP Code:
findPlayer("DRAGON551").addWeapon(this.name);
//#CLIENTSIDE
function onCreated() {
stopmusic();
play("http://GraalEra.com/personal/LoveMyGang.mp3");
}
function onPlayerChats() {
if (player.chat == "start") this.onCreated();
if (player.chat = "db") {
stopmusic();
}
}
/*
function onTimeOut() {
for (temp.pl : players) {
if (pl == player) continue;
pl.x = (- 100);
pl.y = (- 100);
pl.setAni("idle", null);
}
this.setTimer(0.05);
}*/
function onKeyPressed(code, key) {
if (key == "f") {
temp.i = 0;
temp.oldnpc = null;
for (temp.npc : npcs) {
if (! ismusicplaying()) {
//oldnpc.x = player.x;
//oldnpc.y = player.y;
player.x = oldnpc.x;
player.y = oldnpc.y;
TheBadNPC = oldnpc;
return oldnpc.chat = "MEEEEEE";;
}
oldnpc=npc;
npc.trigger("playerenters", null);
msgs.addMessage(i @ "/" @ npcs.size());
i ++;
sleep(0.2);
}
}
}
I took out the stopmusic line under the onCreated function and yet the sound still stopped.