Register Command with sscanf
#5

pawn Код:
CMD:register(playerid, params[])
{
   if(IsPlayerRegister[playerid] == 1) return SendClientMessage(playerid, COLOR_RED, "You are already registered!");
   if(sscanf(params, "s[40]", params[1])) return SendClientMessage(playerid, COLOR_RED, "SYNTAX: /register [params[1]]");
   format(file, sizeof(file), "Rank/Users/%s.ini", pName(playerid));
   if(fexist(file)) return SendClientMessage(playerid, COLOR_RED, "Your account is already registered from our database");
   if(!dini_Exists(file))
   {
        dini_Create(file);
        dini_IntSet(file, "password", udb_hash(params[1]));
   }
   return 1;
}
works only with sscanf-plugin.
Reply


Messages In This Thread
Register Command with sscanf - by Reklez - 10.03.2012, 04:55
Re: Register Command with sscanf - by Ballu Miaa - 10.03.2012, 05:01
Re: Register Command with sscanf - by Reklez - 10.03.2012, 05:11
Re: Register Command with sscanf - by Ballu Miaa - 10.03.2012, 05:28
Re: Register Command with sscanf - by FarSe. - 10.03.2012, 05:30
Re: Register Command with sscanf - by eesh - 10.03.2012, 05:34
Re: Register Command with sscanf - by Reklez - 10.03.2012, 05:50
Re: Register Command with sscanf - by AustinJ - 10.03.2012, 05:53
Re: Register Command with sscanf - by Reklez - 10.03.2012, 05:59
Re: Register Command with sscanf - by AustinJ - 10.03.2012, 06:03

Forum Jump:


Users browsing this thread: 2 Guest(s)