SetPlayerChatBubble
#9

This is login about login

Quote:

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
new sendername[MAX_PLAYER_NAME];
new string[128];
if(response)
{
if(dialogid == 1 || dialogid == 2)
{
if(strlen(inputtext))
{
new tmppass[64];
strmid(tmppass, inputtext, 0, strlen(inputtext), 255);
Encrypt(tmppass);
OnPlayerLogin(playerid,tmppass);
}
else
{
new loginstring[128];
new loginname[64];
GetPlayerName(playerid,loginname,sizeof(loginname) );
format(loginstring,sizeof(loginstring),"POGRESNA SIFRA\nUnesena lozinka se ne poklapa sa accountom!",loginname);
ShowPlayerDialog(playerid,12347,DIALOG_STYLE_INPUT ,"Login",loginstring,"Prijava","Izlaz");
gPlayerLogTries[playerid] += 1;
}
}
if(dialogid == 2)
{
if(strlen(inputtext))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "%s.ini", sendername);
new File: hFile = fopen(string, io_read);
if (hFile)
{
SendClientMessage(playerid, COLOR_YELLOW, "Ime je vec preuzeto, molimo izaberite neko drugo.");
fclose(hFile);
return 1;
}
new tmppass[64];
strmid(tmppass, inputtext, 0, strlen(inputtext), 255);
Encrypt(tmppass);
OnPlayerRegister(playerid,tmppass);
}

Reply


Messages In This Thread
SetPlayerChatBubble - by Stereotype - 08.06.2012, 10:09
Re: SetPlayerChatBubble - by Stereotype - 08.06.2012, 15:33
Re: SetPlayerChatBubble - by MadeMan - 08.06.2012, 15:35
AW: SetPlayerChatBubble - by Tigerkiller - 08.06.2012, 15:36
Re: SetPlayerChatBubble - by Stereotype - 08.06.2012, 15:36
AW: SetPlayerChatBubble - by Tigerkiller - 08.06.2012, 15:38
Re: SetPlayerChatBubble - by MadeMan - 08.06.2012, 15:39
Re: SetPlayerChatBubble - by Stereotype - 08.06.2012, 15:40
Re: SetPlayerChatBubble - by Stereotype - 08.06.2012, 15:46
Re: SetPlayerChatBubble - by MadeMan - 08.06.2012, 15:50

Forum Jump:


Users browsing this thread: 2 Guest(s)