trgameraptor 0 Posted June 14, 2017 Hello friends, The music stops when the player logs in how can I do ? addEventHandler("onClientResourceStart", getResourceRootElement(getThisResource()), function() setTimer(function() playSound("joinsound.mp3") end, 200, 1) end ) Share this post Link to post
pa3ck 207 Posted June 14, 2017 First make sure you keep the sound element in a variable (sound = playSound("...") ) then there is more than likely an event in your code which triggers when the user logs in. If you use the default login system, then there's a server-side event "onPlayerLogin" which you can use to turn off the sound on client-side with a trigger Share this post Link to post
trgameraptor 0 Posted June 14, 2017 1 hour ago, pa3ck said: First make sure you keep the sound element in a variable (sound = playSound("...") ) then there is more than likely an event in your code which triggers when the user logs in. If you use the default login system, then there's a server-side event "onPlayerLogin" which you can use to turn off the sound on client-side with a trigger I could not code Would you help me do it Share this post Link to post