08.07.2010, 13:12
I don't understand why you use "else if" ? Why not just a simple "else" ?
Anyway try this:
Anyway try this:
pawn Код:
new
PlayerName[MAX_PLAYER_NAME],
File[256]
;
GetPlayerName(playerid, PlayerName, sizeof(PlayerName));
format(File, sizeof(File), "CarSys/Users/%s.ini", PlayerName);
if(dini_Exists(File))
{
PlayerInfo[playerid][CarID] = dini_Int(File,"CarID");
PlayerInfo[playerid][OwnCar] = dini_Int(File,"OwnCar");
}
else
{
dini_Create(File);
dini_IntSet(File,"CarID",0);
dini_IntSet(File,"OwnCar",0);
}