Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Release Bad Names Kick Plugin v3.0
04-25-2012, 19:35
Post: #51
RE: Bad Names Kick Plugin v2.0
(04-25-2012 18:20)OzonE Wrote:  bonemind's plugin?
thats the kicking command and shit , exist in every plugin.

I know but can't you modify it to Kick/ban player on entry of server if the person has the name in forbidden.txt?
Related links
Find all posts by this user
Add Thank You Quote this message in a reply
04-26-2012, 07:56
Post: #52
RE: Bad Names Kick Plugin v2.0
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.

Find all posts by this user
Add Thank You Quote this message in a reply
04-26-2012, 08:19 (This post was last modified: 04-26-2012 08:23 by zxz0O0.)
Post: #53
RE: Bad Names Kick Plugin v2.0
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
CSHARP Code
  1. public override void OnPlayerConnect(ServerClient Client)
  2. {
  3.  
  4. string[] cn = Client.Name.Split(' ');
  5. foreach (string x in cn)
  6. {
  7. if (fwords.Contains(x))
  8. ServerSay("^7BadName Plugin ^1Prevented Connection of A ^5Badname Player!", true);
  9. //The kick command will always be executed, no matter what the if tells.
  10. ServerCommand("kick " + Client.ClientNum + "\" Bad Name, ^1Fuck Off!\"");
  11. }
  12.  
  13. }

It should be
CSHARP Code
  1. if (fwords.Contains(x))
  2. {
  3. ServerSay("^7BadName Plugin ^1Prevented Connection of A ^5Badname Player!", true);
  4. ServerCommand("dropClient " + Client.ClientNum + "\" Bad Name, ^1Fuck Off!\"");
  5. }

[Image: azuw.jpg]
Find all posts by this user
Add Thank You Quote this message in a reply
04-26-2012, 14:45
Post: #54
RE: Bad Names Kick Plugin v2.0
(04-26-2012 08:19)zxz0O0 Wrote:  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
CSHARP Code
  1. public override void OnPlayerConnect(ServerClient Client)
  2. {
  3.  
  4. string[] cn = Client.Name.Split(' ');
  5. foreach (string x in cn)
  6. {
  7. if (fwords.Contains(x))
  8. ServerSay("^7BadName Plugin ^1Prevented Connection of A ^5Badname Player!", true);
  9. //The kick command will always be executed, no matter what the if tells.
  10. ServerCommand("kick " + Client.ClientNum + "\" Bad Name, ^1Fuck Off!\"");
  11. }
  12.  
  13. }

It should be
CSHARP Code
  1. if (fwords.Contains(x))
  2. {
  3. ServerSay("^7BadName Plugin ^1Prevented Connection of A ^5Badname Player!", true);
  4. ServerCommand("dropClient " + Client.ClientNum + "\" Bad Name, ^1Fuck Off!\"");
  5. }

Oh now I see xP I'll build another version. zxz thanks a ton!
Related links
Find all posts by this user
Add Thank You Quote this message in a reply
04-26-2012, 15:50
Post: #55
RE: Bad Names Kick Plugin v2.0
Nope... People still get booted out of the match..
Might try one more thing.. if this works then Me Gusta
Can't test my plugin b/c my plugins don't load in my server Dumb Bitch tha fuck Dumb Bitch
Find all posts by this user
Add Thank You Quote this message in a reply
04-28-2012, 21:47
Post: #56
RE: Bad Names Kick Plugin v2.0
@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 xD
aight much help but which part should I change?
Well...i could literally write it but i'm not going to
Since writing an if statement without {} makes the next line only part of it, and multiple lines should be part of it, how about adding {} at the quoted if statement? xD
and no, i'm not trolling by not saying it, just spitting it out wouldn't teach you anything
Now I still need to figure out what's wrong xP
Find all posts by this user
Add Thank You Quote this message in a reply
04-29-2012, 01:59 (This post was last modified: 04-29-2012 02:13 by DidUknowiPwn.)
Post: #57
RE: Bad Names Kick Plugin v2.0
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 Big Grin
Commands I changed to: !badname @GrossKopf thought !plus is silly as well as I did so xP


Attached File(s)
.rar  BadName V3.rar (Size: 5.68 KB / Downloads: 123)
Find all posts by this user
Add Thank You Quote this message in a reply
[-] The following 2 users say Thank You to DidUknowiPwn for this post:
AboAlwe (04-29-2012), OzonE (04-29-2012)
04-29-2012, 09:29
Post: #58
RE: Bad Names Kick Plugin v2.0
(04-28-2012 21:47)DidUknowiPwn Wrote:  @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 xD
aight much help but which part should I change?
Well...i could literally write it but i'm not going to
Since writing an if statement without {} makes the next line only part of it, and multiple lines should be part of it, how about adding {} at the quoted if statement? xD
and no, i'm not trolling by not saying it, just spitting it out wouldn't teach you anything
Now I still need to figure out what's wrong xP
Lol that's what I already said in my previous post.
Related links

[Image: azuw.jpg]
Find all posts by this user
Add Thank You Quote this message in a reply
04-29-2012, 15:35
Post: #59
RE: Bad Names Kick Plugin v2.0
(04-29-2012 09:29)zxz0O0 Wrote:  
(04-28-2012 21:47)DidUknowiPwn Wrote:  @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 xD
aight much help but which part should I change?
Well...i could literally write it but i'm not going to
Since writing an if statement without {} makes the next line only part of it, and multiple lines should be part of it, how about adding {} at the quoted if statement? xD
and no, i'm not trolling by not saying it, just spitting it out wouldn't teach you anything
Now I still need to figure out what's wrong xP
Lol that's what I already said in my previous post.

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 Big Grin
Find all posts by this user
Add Thank You Quote this message in a reply
04-29-2012, 18:20
Post: #60
RE: Bad Names Kick Plugin v2.0
Good Work , Nais.

Find all posts by this user
Add Thank You Quote this message in a reply
[-] The following 1 user says Thank You to OzonE for this post:
DidUknowiPwn (04-29-2012)
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  [Release] Flag plugin for users 1.6 archit 73 4,714 05-23-2013 17:07
Last Post: EnVi Sweden Rocks
  [Release] God Plugin v4.0 [Ingame Rcon Tool] OzonE 312 37,597 05-22-2013 20:21
Last Post: xaliu
  [Release] For Plugin Developers yamraj 4 1,216 05-21-2013 17:55
Last Post: Jone Calerone
  [Release] Chat plugin for permissions SgtLegend 8 313 05-21-2013 11:21
Last Post: SgtLegend
  [Release] Waypoint plugin for users 8q4s8 0 146 05-16-2013 13:10
Last Post: 8q4s8
  [Release] NoKnife Plugin zxz0O0 85 11,107 05-14-2013 21:46
Last Post: Diskretor
  [Release] Bunker Plugin 1.3 archit 56 3,120 05-09-2013 14:13
Last Post: M4cbook
  [Release] Speed Plugin hillbilly 25 3,641 05-06-2013 18:19
Last Post: Hallla
  [Release] Votemap plugin zhp0083 82 11,441 04-12-2013 02:46
Last Post: .sepultura.
Brick [Release] Flag plugin for developers [Z00MBY] Alex 17 1,431 04-06-2013 17:52
Last Post: Dr3am95

Forum Jump:


User(s) browsing this thread: 1 Guest(s)
Media Embeding by Simple Audio Video Embeder