Raised This Month: $ Target: $400
 0% 

amx restrict names


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
play4fun
Junior Member
Join Date: Jul 2006
Old 05-27-2007 , 17:04   amx restrict names
Reply With Quote #1

Code:
#include <amxmodx>
Code:
#define PLUGIN "Restrict_Names_Advanced"
#define VERSION "1.0"
#define AUTHOR "Alka & Jim"
public plugin_init()
{
register_plugin(PLUGIN, VERSION, AUTHOR)
}
public kick(id)
{
server_cmd("kick #%d ^"Change Your Name!You have a restrict name!Don't use nombers and !@#$%^..etc!^"", get_user_userid(id))
}
public client_connect(id)
{
new name[32]
get_user_name(id, name, 31)
if(containi(name, "player") != -1 || containi(name, "unnamed") != -1 || containi(name, "hack") != -1 || containi(name, "admin") != -1 || containi(name, "`") != -1 || containi(name, "~") != -1 || containi(name, "1") != -1 || containi(name, "2") != -1 || containi(name, "3") != -1 || containi(name, "5") != -1 || containi(name, "7") != -1 || containi(name, "8") != -1 || containi(name, "9") != -1 || containi(name, "6") != -1 || containi(name, "0") != -1 || containi(name, "@") != -1 || containi(name, "#") != -1 || containi(name, "$") != -1 || containi(name, "%") != -1 || containi(name, "^") != -1 || containi(name, "&") != -1 || containi(name, "*") != -1 || containi(name, "-") != -1 || containi(name, "=") != -1 )
{
kick(id)
return
}
new i, c
while((c = name[i++]))
{
switch(c)
{
case 31, 32, 33, 34, 35, 36, 37, 38, 40, 41, 42, 64, 94, 123, 125:
{
kick(id)
return
}
}
}
}
Can you tell me were i'm mistaking..srry for my english i whant to make a plugin that kiks all players that contain in their name simbols( !@#$%^&*()_+}{"></.,';][=-)and numbers..Can u tell me where is the eror..because i don't no haw to change the plugin..tks

Srry if i dind't put this topic in the right place

Last edited by play4fun; 05-27-2007 at 17:06. Reason: i think i din't put this topic at the right place srry:((
play4fun is offline
 


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:42.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode