22.08.2013, 17:55
when the user login for the first time, he got a dialog box who ask
him to put is email. It's at this step that I collect the email that i
write on his own .ini file.
I have add the fonction savemailing(playerid);
at the end of code to made the two operation at the same step.
him to put is email. It's at this step that I collect the email that i
write on his own .ini file.
I have add the fonction savemailing(playerid);
at the end of code to made the two operation at the same step.
Quote:
if(dialogid == 1249) { if(response == 1) { if(strlen(inputtext) > 1) { if(strfind(inputtext,"@",true) != -1) { new string3[64]; new playername3[MAX_PLAYER_NAME]; GetPlayerName(playerid, playername3, sizeof(playername3)); format(string3, sizeof(string3), "LARP/Users/%s.ini", playername3); strmid(PlayerInfo[playerid][pEmail], inputtext, 0, 32, 32); dini_Set(string3, "Email",PlayerInfo[playerid][pEmail]); SaveMailing(playerid); ShowPlayerDialog(playerid, 1245, DIALOG_STYLE_INPUT,"Bienvenue, enregistrez-vous","Compte crйe avec succиs!\nTapez votre password pour vous connecter","Log-in","Quitter"); return 1; } else { ShowPlayerDialog(playerid, 1249,DIALOG_STYLE_INPUT, "Enregistrez votre email","Votre adresse n'est pas valide!\nTapez votre email","Ok","Annuler"); } } else { ShowPlayerDialog(playerid, 1249, DIALOG_STYLE_INPUT,"Enregistrez votre email","Vous n'avez pas enregistrй d'email!\nTapez votre email","Ok","Annuler"); } } else { ShowPlayerDialog(playerid, 1249, DIALOG_STYLE_INPUT,"Enregistrez votre email","Vous n'avez pas enregistrй d'email!\nTapez votre email","Ok","Annuler"); } } |