HGAEHaeheadhetdhtertherh (04-22-2016)
Alright this is pretty straight forward so navigate to wServer/networking/handlers/PlayerTextHandler.cs
Now find the else statement that contains
and just add this after itCode:if (client.Player.Muted) { client.Player.SendInfo("{\"key\":\"server.muted\"}"); return; }
feel free to edit the if statement to your needs (:Code:if (packet.Tex*****ntains("need") && packet.Tex*****ntains("items") || packet.Tex*****ntains("free") && packet.Tex*****ntains("items") || packet.Tex*****ntains("give") && packet.Tex*****ntains("items")) { client.Player.SendError("Don't beg!"); return; }
HGAEHaeheadhetdhtertherh (04-22-2016)
Wouldnt this only work if a player used all the words combined? Since your using && instead of || (or)
Do like items && free || give && please blah blah blah etc. Also add like "this is based on keywords so if you werent begging just ignore" to the send message maybe
Last edited by Riigged; 12-06-2015 at 09:24 AM.
Oh im on mobile so all i say was && lol had to scroll to right to see the ||
- - - Updated - - -
and instead of telling it to senderror, have it just not send the text at all if they say the combination of keywords
Last edited by Riigged; 12-06-2015 at 02:14 PM.
you could do an array like
string[] begWords = {"Item", "Free", "Plz" }
would make the code shorter mate.
NotKierze (12-08-2015)
Or just ban them.
YEP cock
With the right word combos this might work![]()