Sorry for double post here is my code i dont know how to put it,
sorry for my bad english..
Код:
if (strcmp(cmd, "/login", true) == 0)
{
if(!IsPlayerNPC(playerid))
{
if(IsPlayerConnected(playerid))
{
new tmppass[64];
if(gPlayerLogged[playerid] == 1)
{
SendClientMessage(playerid, TEAM_AZTECAS_COLOR, "SERVER: You are already logged in.");
return 1;
}
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_YELLOW, "USAGE: /login [password]");
return 1;
}
strmid(tmppass, tmp, 0, strlen(cmdtext), 255);
//Encrypt(tmppass);
OnPlayerLogin(playerid,tmppass);
GetPlayerName(playerid,sendername,sizeof(sendername));
new playersip[128];
GetPlayerIp(playerid,playersip,sizeof(playersip));
new d,m,y;
new h,mi,s;
getdate(y,m,d);
gettime(h,mi,s);
format(string,sizeof(string),"(%d/%d/%d)[%d:%d:%d] %s Has Logged In [IP: %s]",d,m,y,h,mi,s,sendername, playersip);
LoginLog(string);
}
}
return 1;
}