LiOneLMeSsIShoT Posted August 23, 2013 Posted August 23, 2013 This script's not working....When i try to join..i don't hear anything...also added the sound to Meta.xml function onJoin () local sound = playSound ("Login_System/Sounds/ZombieSound.mp3") end addEventHandler ("onClientPlayerJoin", getRootElement(), onJoin)
DNL291 Posted August 23, 2013 Posted August 23, 2013 Any erros in debugscript? (Login_System is the resource name or a folder?)
LiOneLMeSsIShoT Posted August 23, 2013 Author Posted August 23, 2013 Any erros in debugscript?(Login_System is the resource name or a folder?) Sure the name of the Folder
PotatoHead Posted August 23, 2013 Posted August 23, 2013 You dont need the Folder name if the .lua script is in there. Just the sounds folder should do.
LiOneLMeSsIShoT Posted August 23, 2013 Author Posted August 23, 2013 You dont need the Folder name if the .lua script is in there. Just the sounds folder should do. that script in Client/client.lua so i must give the script the full way? .. I guess
iPrestege Posted August 23, 2013 Posted August 23, 2013 You want to play the sound for the player how that just joined or for everyone in the server if someone join the server?
PotatoHead Posted August 23, 2013 Posted August 23, 2013 Okay E.G. My script is in Login-System/login_c.lua. If my sound file is in Login-System/sounds/sound.mp3 then this would be the code playSound("sounds/sound.mp3") I am not the best at this yet but that's how I would do it.
LiOneLMeSsIShoT Posted August 23, 2013 Author Posted August 23, 2013 You want to play the sound for the player how that just joined or for everyone in the server if someone join the server? Yeah! and stops the song when the player Login
iPrestege Posted August 23, 2013 Posted August 23, 2013 Sorry but this didn't help me choose for the player just joined or for everyone?
LiOneLMeSsIShoT Posted August 23, 2013 Author Posted August 23, 2013 Sorry but this didn't help me choose for the player just joined or for everyone? For anyone Join to the server...Get the song...after he login..the song be shuted the fuck up and gone .
Castillo Posted August 23, 2013 Posted August 23, 2013 onClientPlayerJoin is triggered by remote players only, use onClientResourceStart instead.
LiOneLMeSsIShoT Posted August 25, 2013 Author Posted August 25, 2013 onClientPlayerJoin is triggered by remote players only, use onClientResourceStart instead. It will start the song when the resource start, i want it starts when the player join to the server, whatever when he login..the Song stops
Castillo Posted August 25, 2013 Posted August 25, 2013 You can check if the player is logged in or not.
LiOneLMeSsIShoT Posted August 25, 2013 Author Posted August 25, 2013 You can check if the player is logged in or not. How?> What script? and what script to stop the song? not to pause it.
iPrestege Posted August 25, 2013 Posted August 25, 2013 onPlayerLogin triggerClientEvent isElement destroyElement
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