24.05.2013, 09:12
Dini don't saving the registered players.
Код:
if(dialogid == REGISTER) { new file[128]; new pName[MAX_PLAYER_NAME]; GetPlayerName(playerid, pName, sizeof(pName)); format(file, sizeof(file), "%s.ini", pName); if(!response) return SendClientMessage(playerid, COLOR_RED, "Success Quit!"), Kick(playerid); if(strlen(inputtext) < 3 || strlen(inputtext) > 20) return SendClientMessage(playerid, COLOR_PLAYER, "SERVER: Lenght from 3 to 20."), ShowPlayerDialog(playerid, REGISTER, DIALOG_STYLE_PASSWORD, "{FFFF00}Registration:", "{FFFFFE}Your account isn't registered. Please type your password.", "Register", "Quit"); GetPlayerIp(playerid, PlayerInfo[playerid][pIPaddress], 15); dini_Create(file); dini_IntSet(file, "pPwd", udb_hash(inputtext)); dini_IntSet(file, "pAdmin", PlayerInfo[playerid][pAdmin] = 0); dini_IntSet(file, "pHide", PlayerInfo[playerid][pHide] = 0); dini_IntSet(file, "aDuty", PlayerInfo[playerid][aDuty] = 0); dini_IntSet(file, "aTog", PlayerInfo[playerid][aTog] = 0); dini_IntSet(file, "pMember", PlayerInfo[playerid][pMember] = 0); dini_IntSet(file, "pVipRank", PlayerInfo[playerid][pVipRank] = 0); dini_IntSet(file, "pCop", PlayerInfo[playerid][pCop] = 0); dini_IntSet(file, "pBanned", PlayerInfo[playerid][pBanned] = 0); dini_IntSet(file, "pCash", PlayerInfo[playerid][pCash] = 0); dini_IntSet(file, "pMuted", PlayerInfo[playerid][pMuted] = 0); dini_IntSet(file, "ptMuted", PlayerInfo[playerid][ptMuted] = 0); dini_IntSet(file, "pWarn", PlayerInfo[playerid][pWarn] = 0); dini_IntSet(file, "pJail", PlayerInfo[playerid][pJail] = 0); dini_IntSet(file, "pJailTime", PlayerInfo[playerid][pJailTime] = 0); dini_IntSet(file, "pRadio", PlayerInfo[playerid][pRadio] = 0); dini_IntSet(file, "pDice", PlayerInfo[playerid][pDice] = 0); dini_IntSet(file, "pFlowers", PlayerInfo[playerid][pFlowers] = 0); dini_IntSet(file, "pCamera", PlayerInfo[playerid][pCamera] = 0); dini_IntSet(file, "pBoat", PlayerInfo[playerid][pBoat] = 0); dini_IntSet(file, "pHelicopter", PlayerInfo[playerid][pHelicopter] = 0); dini_IntSet(file, "pAirplane", PlayerInfo[playerid][pAirplane] = 0); dini_IntSet(file, "pBadge", PlayerInfo[playerid][pBadge] = 0); format(string, sizeof(string), "SERVER: Success registered! %s", pName); SendClientMessage(playerid, COLOR_YELLOW, string); IsPlayerLogged[playerid] = 1; }