enzopaul4 Posted October 22, 2016 Share Posted October 22, 2016 Why not working?Why?Cai?Vai?? Pz Help plz function play () local sound = playSound("resources/christmasde.mp3") setSoundVolume(sound, 0.5) end addEventHandler("onPlayerJoin", localPlayer,) Link to comment
Simple0x47 Posted October 22, 2016 Share Posted October 22, 2016 It's because you're using a client-only function into server-side. Try this CLIENT: function playThatSound() local sound = playSound("resources/christmasde.mp3") setSoundVolume(sound, 0.5) end addEventHandler("onClientResourceStart", root, playThatSound) Link to comment
2013martin1212 Posted October 22, 2016 Share Posted October 22, 2016 function play() sound = playSound("resources/christmasde.mp3",true) setSoundVolume(sound,0.5) end addEventHandler("onPlayerJoin",playSound) try this way Link to comment
enzopaul4 Posted October 22, 2016 Author Share Posted October 22, 2016 OMG OMG OMG THX THX THX THX Link to comment
Simple0x47 Posted October 22, 2016 Share Posted October 22, 2016 5 minutes ago, 2013martin1212 said: function play() sound = playSound("resources/christmasde.mp3",true) setSoundVolume(sound,0.5) end addEventHandler("onPlayerJoin",playSound) try this way It would give error, cuz first theres use of client-side only functions like playSound, and then the onPlayerJoin it's serverside and calls a client-side only function that's pretty strange. Use the one I've posted before. Link to comment
2013martin1212 Posted October 22, 2016 Share Posted October 22, 2016 np happy to help Link to comment
enzopaul4 Posted October 22, 2016 Author Share Posted October 22, 2016 O guyz i'm so happy =)) Link to comment
Simple0x47 Posted October 22, 2016 Share Posted October 22, 2016 (edited) 4 minutes ago, 2013martin1212 said: np happy to help The next time try to help for real, cuz your script has base errors. Edited October 22, 2016 by Simple01 Link to comment
enzopaul4 Posted October 22, 2016 Author Share Posted October 22, 2016 Just now, Simple01 said: The next time try to help for real, cuz your script has base errors. YEHH , i am biginner . and i am very bad.. but neah , i want to make my best Link to comment
Simple0x47 Posted October 22, 2016 Share Posted October 22, 2016 No no, I was talking about @2013martin1212 Link to comment
2013martin1212 Posted October 22, 2016 Share Posted October 22, 2016 i no not the best scripter i am but if works then works Link to comment
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