enum bInfo
{
Name[128],
Owner[MAX_PLAYER_NAME],
Float: Pozicija[3],
Float: Interijer[10],
Zakljucan,
Cijena,
PickupID,
Text3D: LabelID
};
new BiznisInfo[MAX_BIZNISA][bInfo];
// Informacije - Spremanje BIZNIS podataka
new INI:bFile = INI_Open(BiznisPath(playerid));
INI_SetTag(bFile,"data");
for(new i = 0; i != MAX_BIZNISA; i++)
INI_WriteString(bFile,"Ime",BiznisInfo[i][Name]);
INI_WriteString(bFile,"Owner",BiznisInfo[i][Owner]);
INI_WriteInt(bFile,"Pozicija",BiznisInfo[i][Pozicija]);
INI_WriteInt(bFile,"Interijer",BiznisInfo[i][Interijer]);
INI_WriteString(bFile,"Zakljucan",BiznisInfo[i][Zakljucan]);
INI_WriteInt(bFile,"Cijena",BiznisInfo[i][Cijena]);
INI_WriteInt(bFile,"PickupID",BiznisInfo[i][PickupID]);
INI_WriteInt(bFile,"LabelID",BiznisInfo[i][LabelID]);
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(1694) : error 017: undefined symbol "i"
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(1695) : error 017: undefined symbol "i"
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(1696) : error 017: undefined symbol "i"
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(1697) : error 017: undefined symbol "i"
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(1698) : error 017: undefined symbol "i"
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(1699) : error 017: undefined symbol "i"
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(1700) : error 017: undefined symbol "i"
stock LoadBiznis_data(playerid,name[],value[])
{
for(new i = 0; i != MAX_BIZNISA; i++)
INI_Int("Ime",BiznisInfo[i][Name]);
INI_Int("Owner",BiznisInfo[i][Owner]);
INI_Int("Pozicija",BiznisInfo[i][Pozicija]);
INI_Int("Interijer",BiznisInfo[i][Interijer]);
INI_Int("Zakljucan",BiznisInfo[i][Zakljucan]);
INI_Int("Cijena",BiznisInfo[i][Cijena]);
INI_Int("PickupID",BiznisInfo[i][PickupID]);
INI_Int("LabelID",BiznisInfo[i][LabelID]);
return 1;
}
for(new i = 0; i != MAX_BIZNISA; i++)
INI_WriteString(bFile, "Ime", BiznisInfo[i][Name]);
new
INI:bFile = INI_Open(BiznisPath(playerid))
;
INI_SetTag(bFile,"data");
for(new i = 0; i != MAX_BIZNISA; i++)
{
INI_WriteString(bFile, "Ime", BiznisInfo[i][Name]);
INI_WriteString(bFile, "Owner", BiznisInfo[i][Owner]);
INI_WriteInt(bFile, "Pozicija", BiznisInfo[i][Pozicija]);
INI_WriteInt(bFile, "Interijer", BiznisInfo[i][Interijer]);
INI_WriteString(bFile, "Zakljucan", BiznisInfo[i][Zakljucan]);
INI_WriteInt(bFile, "Cijena", BiznisInfo[i][Cijena]);
INI_WriteInt(bFile, "PickupID", BiznisInfo[i][PickupID]);
INI_WriteInt(bFile, "LabelID", BiznisInfo[i][LabelID]);
}
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(1692) : warning 213: tag mismatch
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(1693) : warning 213: tag mismatch
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(1697) : warning 213: tag mismatch
INI_WriteInt(bFile, "Pozicija", BiznisInfo[i][Pozicija]);
INI_WriteInt(bFile, "Interijer", BiznisInfo[i][Interijer]);
INI_WriteInt(bFile, "LabelID", BiznisInfo[i][LabelID]);
INI_WriteFloat(bFile, "Pozicija_X", BiznisInfo[i][Pozicija][0]);
INI_WriteFloat(bFile, "Pozicija_Y", BiznisInfo[i][Pozicija][1]);
INI_WriteFloat(bFile, "Pozicija_Z", BiznisInfo[i][Pozicija][2]);
- Pozicija and Interijer arrays are floats, not integers (INI_WriteFloat).
- They're also arrays so you have to save each index separate (for example): pawn Код:
- Why do you save them under OnPlayerDisconnect instead of OnGameModeExit (as it should be)? |