Hallo,
wie speicher ich hier
if (strcmp(cmd, "/register", true)==0)
{
new string1[265];
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, Gelb, "Benutze: /register [password]");
return 1;
}
if (gPlayerAccount[playerid] == 1)
{
SendClientMessage(playerid, Gelb, "Dieser Name ist bereits registriert!");
return 1;
}
strmid(PlayerInfo[playerid][Passwort], tmp, 0, strlen(cmdtext), 255);
Encrypt(PlayerInfo[playerid][Passwort]);
GetPlayerName(playerid, playername, sizeof(playername));
format(string1, sizeof(string1), "/Spieler/%s.cer", playername);
new File: file = fopen(string1, io_read);
if (file)
{
SendClientMessage(playerid, Gelb, "Dieser Name ist schon registriert!");
fclose(file);
return 1;
}
new File:hFile;
hFile = fopen(string1, io_append);
new var[32];//
format(var, 32, "%s\n", PlayerInfo[playerid][Passwort]);fwrite(hFile, var);
format(var, 32, "Morde=%d\n",PlayerInfo[playerid][morde]);fwrite(hFile, var);
format(var, 32, "Tode=%d\n",PlayerInfo[playerid][tode]);fwrite(hFile, var);
PlayerInfo[playerid][geld] = GetPlayerMoney(playerid);
format(var, 32, "Geld=%d\n",PlayerInfo[playerid][geld]);fwrite(hFile, var);
format(var, 32, "Führerschein=%d\n",PlayerInfo[playerid][autoschein]);fwrite(hFile, var);
format(var, 32, "Leader=%d\n",PlayerInfo[playerid][leader]);fwrite(hFile, var);
format(var, 32, "SkinID=%d\n",PlayerInfo[playerid][skin]);fwrite(hFile, var);
fclose(hFile);
SendClientMessage(playerid, Hellblau, "Du hast dich erfolgreich registriert!!");
SendClientMessage(playerid, Hellblau, "Beim nächsten besuch benutze /register password.");
OnPlayerLogin(playerid,PlayerInfo[playerid][Passwort]);
return 1;
}
den skin des spielers? Habe schon bei meinem pInfo skin gemacht weis aber net wie es geht
MfG