Anyone wants to edit this tiny piece of script?
#1

This is a part of the script from the ladmin script, i want to make it that if a player name is registered he has to login before he can play, and if he isn't registered he can just play but he can register at any time, i would be so happy if just someone want to do this.



if(!udb_Exists(PlayerName2(playerid))) SendClientMessage(playerid,orange, "ACCOUNT: Type /register [password] to create an account");
else
{
PlayerInfo[playerid][Registered] = 1;
format(file,sizeof(file),"/ladmin/users/%s.sav",udb_encode(PlayerName));
new tmp2[256]; tmp2 = dini_Get(file,"ip");
if( (!strcmp(tmp3,tmp2,true)) && (ServerInfo[AutoLogin] == 1) )
{
LoginPlayer(playerid);
if(PlayerInfo[playerid][Level] > 0)
{
format(string,sizeof(string),"ACCOUNT: You have been automatically logged in. (Level %d)", PlayerInfo[playerid][Level] );
SendClientMessage(playerid,green,string);
}
else SendClientMessage(playerid,green,"ACCOUNT: You have been automatically logged in.");
}
else SendClientMessage(playerid, green, "ACCOUNT: This nickname is registed, you can now login by typing /login [password]");
}
return 1;
}
Reply
#2

Script Request Thread.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)