04-25-2012, 19:35
|
Release Bad Names Kick Plugin v3.0
|
|
04-26-2012, 07:56
i think the bug is in the strings shit , it checks every character of it , i think we have to modify to make it read the name only.
Explaining problems according to source code on page 1:
- kick command is for name not for ClientNum - Since you are splitting the name, people who use name like aFucka don't get kicked - You are comparing with case sensitive - Using if clause wrong Code: public override void OnPlayerConnect(ServerClient Client)
{
string[] cn = Client.Name.Split(' ');
foreach (string x in cn)
{
if (fwords.Contains(x))
ServerSay("^7BadName Plugin ^1Prevented Connection of A ^5Badname Player!", true);
//The kick command will always be executed, no matter what the if tells.
ServerCommand("kick " + Client.ClientNum + "\" Bad Name, ^1Fuck Off!\"");
}
}Code: if (fwords.Contains(x))
{
ServerSay("^7BadName Plugin ^1Prevented Connection of A ^5Badname Player!", true);
ServerCommand("dropClient " + Client.ClientNum + "\" Bad Name, ^1Fuck Off!\"");
}
04-26-2012, 14:45
(04-26-2012, 08:19)zxz0O0 Wrote: Explaining problems according to source code on page 1: Oh now I see xP I'll build another version. zxz thanks a ton!
04-26-2012, 15:50
Nope... People still get booted out of the match..
Might try one more thing.. if this works then ![]() Can't test my plugin b/c my plugins don't load in my server tha fuck
04-28-2012, 21:47
@bonemind thanks for info..
Quote:I think this is wrong, When you write the if statement without {}, only the line below it is consideren part of it, so this piece of code executes ServerSay if a forbidden word is found, and then bans the player anyway xDNow I still need to figure out what's wrong xP
04-29-2012, 01:59
(This post was last modified: 04-29-2012, 02:13 by DidUknowiPwn.)
Aight 100% fixed tested this over 10 times with different names, people, and commands. Will upload soon.
Ok guys finally it's now ready! This time it won't kick/ban everyone Commands I changed to: !badname @GrossKopf thought !plus is silly as well as I did so xP
04-29-2012, 09:29
(04-28-2012, 21:47)DidUknowiPwn Wrote: @bonemind thanks for info..Lol that's what I already said in my previous post.Quote:I think this is wrong, When you write the if statement without {}, only the line below it is consideren part of it, so this piece of code executes ServerSay if a forbidden word is found, and then bans the player anyway xDNow I still need to figure out what's wrong xP
04-29-2012, 15:35
(04-29-2012, 09:29)zxz0O0 Wrote:(04-28-2012, 21:47)DidUknowiPwn Wrote: @bonemind thanks for info..Lol that's what I already said in my previous post.Quote:I think this is wrong, When you write the if statement without {}, only the line below it is consideren part of it, so this piece of code executes ServerSay if a forbidden word is found, and then bans the player anyway xDNow I still need to figure out what's wrong xP Ya and I just saw it as well. The reason yours didn't work is because you can't add a reason for the kick once removed and added {} it worked flawlessly... So much fail on both of our parts
04-29-2012, 18:20
Good Work , Nais.
|
| Possibly Related Threads… | |||||
| Thread | Author | Replies | Views | Last Post | |
|
|
[Release] Plugin ReservedSlot v1.3 | frst_ | 1 | 4,996 |
11-08-2018, 19:17 Last Post: frst_ |
|
|
[Release] MW3 Shop plugin | Dude | 56 | 51,301 |
03-25-2018, 05:18 Last Post: [email protected] |
| [Release] Permission plugin | Pozzuh | 202 | 163,920 |
05-01-2017, 15:41 Last Post: W4R||The Hyper |
|
| [Release] FIXED SPEED PLUGIN | hillbilly | 2 | 5,656 |
06-02-2016, 20:23 Last Post: clacki |
|
| [Release] Bots Plugin For Users | Casper | 22 | 39,849 |
08-22-2015, 17:45 Last Post: SnapBacks |
|
| [Release] God Plugin v5.0 [Ingame Rcon Tool] | OzonE | 464 | 335,775 |
06-27-2015, 15:38 Last Post: bluedot |
|
| [Release] Anti Hardscope Plugin | 8q4s8 | 26 | 27,593 |
06-20-2015, 22:44 Last Post: urj88419 |
|
| [Release] ProMod Plugin | zxz0O0 | 875 | 761,608 |
03-25-2015, 22:02 Last Post: kris |
|
| [Release] [Discontinued] Speed Plugin | Pozzuh | 164 | 121,944 |
10-06-2014, 12:56 Last Post: Nekochan |
|
| [help]how create a ping plugin | clacki | 3 | 5,076 |
09-13-2014, 01:23 Last Post: clacki |
|
| Users browsing this thread: |
| 2 Guest(s) |



![[Image: back_us_button.png]](http://static.squarespace.com/static/51cca4bae4b0bf9a1f4deb75/t/52ea6a9ee4b0f767960f8c35/1390493521990/back_us_button.png)

tha fuck