28.04.2010, 18:47
Hi..i wanted to make my clan tag to be useable by my admins only and did that:
if I don't try to make it usable for my clanmembers (leave the !strcmp(pNam) out) it works and kicks the tag users...
Код:
new string[256], msg[255], reas[254], nam[MAX_PLAYER_NAME]; GetPlayerName(playerid, nam, sizeof(nam)); format(string, sizeof(string), "%s", nam); new pNam[50]; GetPlayerName(playerid, pNam, 50); if(!strcmp(pNam, "TAG Name", true) || (pNam, "TAG Name2", true)){ }else{ if(strfind(string, "TAG", true) != -1){ format(msg, sizeof(msg), "Bot kicked %s", nam); format(reas, sizeof(reas), "Reason: Unauthorized using of Tag."); SendClientMessageToAll(RED, msg); SendClientMessageToAll(RED, reas); SendClientMessage(playerid, WHITE, "---------------------------------------------------------------------"); SendClientMessage(playerid, YELLOW, "You are not allowed to use the Tag. Please choose another name"); SendClientMessage(playerid, WHITE, "---------------------------------------------------------------------"); Kick(playerid); } }