Adding names
#2

pawn Код:
new szName[25];
GetPlayerName(playerid, szName, sizeof(szName));
new string[40];
format(string, sizeof(string), "[ADMIN]%s", szName);
SetPlayerName(playerid, string);
Use that for the first part. Untested.

And for the second, use this under OnPlayerConnect.

pawn Код:
new szName[25];
GetPlayerName(playerid, szName, sizeof(szName));
if(strfind(szName, "admin", true) != -1) Kick(playerid);
Untested. I may have messed up the strfind syntax- I don't use that function very often.
Reply


Messages In This Thread
Adding names - by BleverCastard - 25.04.2012, 21:06
Re: Adding names - by Scenario - 25.04.2012, 21:19
Re: Adding names - by Kindred - 25.04.2012, 21:21
Re: Adding names - by Jonny5 - 25.04.2012, 21:21
Re: Adding names - by ReneG - 25.04.2012, 21:24
Re: Adding names - by Jonny5 - 25.04.2012, 21:27
Re: Adding names - by BleverCastard - 25.04.2012, 21:32
Re: Adding names - by Elysian` - 25.04.2012, 21:34
Re: Adding names - by BleverCastard - 25.04.2012, 21:36
Re: Adding names - by Jonny5 - 25.04.2012, 21:47

Forum Jump:


Users browsing this thread: 1 Guest(s)