iMr.3a[Z]eF Posted February 13, 2013 Share Posted February 13, 2013 (edited) i don't know what is the wrong code please help me the script is when anyone say bad word he'll get mute. but this isn't work Words = { ["sever"] = true, } ----- Muting Function addEventHandler("onPlayerChat", getRootElement(), function(msg, msgType) local theMsg = msg if Words[theMsg] then cancelEvent() pName = getPlayerName(source) outputChatBox(" (( #FFFFFF".. pName .." #ff0000 )) #808080 Have Been Muted By Consle Rason = Bad Mouth",getRootElement(),255,0,0,true) setTimer (function ( player , ... ) setPlayerMuted(source, true) setTimer(unmute(player),tonumber(muteTime)*300000,1) outputChatBox(" (( #FFFFFF".. pName .." #0000ff )) #ff0000 You Have Been UnMuted By Consle Don't Try That Agine",getRootElement(),255,0,0,true) end, 300000 ,1, true ) end end ) Edited February 13, 2013 by Guest Link to comment
||BuLLeT|| Posted February 13, 2013 Share Posted February 13, 2013 there are no words? Link to comment
iMr.3a[Z]eF Posted February 13, 2013 Author Share Posted February 13, 2013 yea there are words but so bad i just don't want to write them** Link to comment
HunT Posted February 13, 2013 Share Posted February 13, 2013 setTimer (function ( player , ... ) -- close the setTimer Link to comment
iMr.3a[Z]eF Posted February 13, 2013 Author Share Posted February 13, 2013 didn't work! Link to comment
iPrestege Posted February 13, 2013 Share Posted February 13, 2013 Words = { ["sever"] = true, } ----- Muting Function addEventHandler("onPlayerChat", getRootElement(), function(msg, msgType) local theMsg = msg if Words[theMsg] then cancelEvent() pName = getPlayerName(source) outputChatBox(" (( #FFFFFF".. pName .." #ff0000 )) #808080 Have Been Muted By Consle Rason = Bad Mouth",getRootElement(),255,0,0,true) setPlayerMuted(source, true) setTimer (function ( player ) setPlayerMuted (player, false ) outputChatBox(" (( #FFFFFF".. pName .." #0000ff )) #ff0000 You Have Been UnMuted By Consle Don't Try That Agine",getRootElement(),255,0,0,true) end, 300000,1, source ) end end ) Should Have Admin Rights | resource.Name Link to comment
iMr.3a[Z]eF Posted February 13, 2013 Author Share Posted February 13, 2013 thank you. but what i'll write here resource."here" the script name or? Link to comment
iPrestege Posted February 13, 2013 Share Posted February 13, 2013 (edited) Yes Script Name Add it To "Admin" Group "ACL" . Example : resource.Mute_System Edited February 13, 2013 by Guest Link to comment
iMr.3a[Z]eF Posted February 13, 2013 Author Share Posted February 13, 2013 thank you so much i'll see if its works or no Link to comment
iPrestege Posted February 13, 2013 Share Posted February 13, 2013 No Problem But Should Work On Server Side . Link to comment
iMr.3a[Z]eF Posted February 13, 2013 Author Share Posted February 13, 2013 Didn't works too Link to comment
iPrestege Posted February 13, 2013 Share Posted February 13, 2013 I've tested now and it works , Show you,re meta.xml . Link to comment
iMr.3a[Z]eF Posted February 13, 2013 Author Share Posted February 13, 2013 http://www.m5zn.com/newuploads/2013/02/ ... f66ab4.jpg\ LOOK at picture Link to comment
iPrestege Posted February 13, 2013 Share Posted February 13, 2013 http://www.m5zn.com/newuploads/2013/02/13/jpg//m5zn_b819f752bf66ab4.jpg\LOOK at picture Not resources !! Should to be : resource.KLAM-WS5 -_-" Link to comment
iMr.3a[Z]eF Posted February 13, 2013 Author Share Posted February 13, 2013 (edited) lol i wrong ! my bad Edited February 13, 2013 by Guest Link to comment
iPrestege Posted February 13, 2013 Share Posted February 13, 2013 i know that but copy this and paste it on the add object : resource.KLAM-WS5 Link to comment
iMr.3a[Z]eF Posted February 13, 2013 Author Share Posted February 13, 2013 that's works thank you!! 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