Jump to content

I need help.


GamerDeMTA

Recommended Posts

"onPlayerChat" 
triggerClientEvent 
addEvent 
addEventHandler 
playSound 
  

But What I shall do with that code? Okay, Put it in a .lua, and how to add the words? And the sound? And If i want more than 1 sound? and Thanks!!! And I must put some lines in any XML, or anything smilar?

SORRY FOR MY BAD ENGLISH :S

Link to comment

Full Script Just Create Lua Files And META.XML And Add The Sound To The Meta And Here You Are The Code :

Client Script :

function ClientSide() 
playSound ("Name.mp3") 
end 
addEvent("Client",true, ClientSide ) 
addEventHandler("Client",root, ClientSide ) 

Server Script :

addEventHandler("onPlayerChat", root, 
    function ( msg ) 
        if msg == "wtf" then 
triggerClientEvent ("Client",root) 
      end 
end) 

Meta.Xml :

    "Name.mp3" /> 
    

Have Fun :wink:

Link to comment
Full Script Just Create Lua Files And META.XML And Add The Sound To The Meta And Here You Are The Code :

Client Script :

function ClientSide() 
playSound ("Name.mp3") 
end 
addEvent("Client",true, ClientSide ) 
addEventHandler("Client",root, ClientSide ) 

Server Script :

addEventHandler("onPlayerChat", root, 
    function ( msg ) 
        if msg == "wtf" then 
triggerClientEvent ("Client",root) 
      end 
end) 

Meta.Xml :

    "Name.mp3" /> 
    

Have Fun :wink:

Thanks to all, you were very kind with me :D

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...