micheal1230 Posted May 19, 2012 Posted May 19, 2012 The Error is BASS ERROR 2 in LoadMedia path:C:\Program Files\MTA San Andreas 1.3\mods\deathmatch\resources\worldmusic-system\time-to-say-goodbye 3d:0 loop:0 ClientSide: function soundplayer(soundname) if (thesound) then stopSound(thesound) end thesound = playSound(soundname, false) setSoundVolume(thesound, 0.5) end addEvent("onClientPlayMP3", true) addEventHandler("onClientPlayMP3", getRootElement(), soundplayer) --Volume Controls function louder() outputChatBox("MP3 Volume is at Max.", source) setSoundVolume(thesound, 1.0) end addCommandHandler("mp3up", louder) function quieter() outputChatBox("MP3 volume now at 25%", source) setSoundVolume(thesound, 0.25) end addCommandHandler("mp3down", quieter) function stfu() outputChatBox("MP3 now stopped.", source) stopSound(thesound) end addCommandHandler("musicoff", stfu) addEvent("onClientStopMP3", true) addEventHandler("onClientStopMP3", getRootElement(), stfu) ServerSide: function playthatsound(sourcePlayer, command, song) if (exports.global:isPlayerHeadAdmin(sourcePlayer)) then --local thesong = soundname .. ".mp3" local soundname = song triggerClientEvent( "onClientPlayMP3", getRootElement(), soundname) end end addCommandHandler("playmp3", playthatsound) function stfuserver(sourcePlayer, command) if (exports.global:isPlayerHeadAdmin(sourcePlayer)) then triggerClientEvent( "onClientStopMP3", getRootElement()) end end addCommandHandler("stopmp3", stfuserver)
Jaysds1 Posted May 19, 2012 Posted May 19, 2012 Sorry, I don't see anything wrong in the script, What's the name of the song? My in-game name: Jaysds1 Retired CMG Scripter World Of Tanks GameMode (Open-Source): https://github.com/Jaysds1/mtasa-wot-gamemode Online GUI-Editor (WIP): https://forum.mtasa.com/topic/47678-online-gui-editor/
micheal1230 Posted May 19, 2012 Author Posted May 19, 2012 Sorry, I don't see anything wrong in the script,What's the name of the song? time-to-say-goodbye
Jaysds1 Posted May 19, 2012 Posted May 19, 2012 where's the .mp3? My in-game name: Jaysds1 Retired CMG Scripter World Of Tanks GameMode (Open-Source): https://github.com/Jaysds1/mtasa-wot-gamemode Online GUI-Editor (WIP): https://forum.mtasa.com/topic/47678-online-gui-editor/
micheal1230 Posted May 19, 2012 Author Posted May 19, 2012 where's the .mp3? In the worldmusic-system folder
micheal1230 Posted May 19, 2012 Author Posted May 19, 2012 The Error is BASS ERROR 2 in LoadMedia path:C:\Program Files\MTA San Andreas 1.3\mods\deathmatch\resources\worldmusic-system\time-to-say-goodbye 3d:0 loop:0 ClientSide: function soundplayer(soundname) if (thesound) then stopSound(thesound) end thesound = playSound(soundname, false) setSoundVolume(thesound, 0.5) end addEvent("onClientPlayMP3", true) addEventHandler("onClientPlayMP3", getRootElement(), soundplayer) --Volume Controls function louder() outputChatBox("MP3 Volume is at Max.", source) setSoundVolume(thesound, 1.0) end addCommandHandler("mp3up", louder) function quieter() outputChatBox("MP3 volume now at 25%", source) setSoundVolume(thesound, 0.25) end addCommandHandler("mp3down", quieter) function stfu() outputChatBox("MP3 now stopped.", source) stopSound(thesound) end addCommandHandler("musicoff", stfu) addEvent("onClientStopMP3", true) addEventHandler("onClientStopMP3", getRootElement(), stfu) ServerSide: function playthatsound(sourcePlayer, command, song) if (exports.global:isPlayerHeadAdmin(sourcePlayer)) then --local thesong = soundname .. ".mp3" local soundname = song triggerClientEvent( "onClientPlayMP3", getRootElement(), soundname) end end addCommandHandler("playmp3", playthatsound) function stfuserver(sourcePlayer, command) if (exports.global:isPlayerHeadAdmin(sourcePlayer)) then triggerClientEvent( "onClientStopMP3", getRootElement()) end end addCommandHandler("stopmp3", stfuserver) Fixed it you needed to do /mp3play time_to_say_goodbye.mp3
Jaysds1 Posted May 20, 2012 Posted May 20, 2012 You could get the song meta instead of typing in the song name My in-game name: Jaysds1 Retired CMG Scripter World Of Tanks GameMode (Open-Source): https://github.com/Jaysds1/mtasa-wot-gamemode Online GUI-Editor (WIP): https://forum.mtasa.com/topic/47678-online-gui-editor/
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now