SA-MP Forums Archive
[INI_String] Error - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: [INI_String] Error (/showthread.php?tid=578840)



[INI_String] Error - NoDi522 - 22.06.2015

What does cause this ini string error:

PHP код:
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(3710) : error 001expected token")"but found "["
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(3710) : warning 215expression has no effect
C
:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(3710) : error 001expected token";"but found "]"
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(3710) : error 029invalid expressionassumed zero
C
:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(3710) : fatal error 107too many error messages on one line 
PHP код:
INI_String("Novac",PlayerInfo[playerid][pNovac],32); // When i remove '32' error is "undefined symbol INI_String" 



Re: [INI_String] Error - PeterJane - 22.06.2015

Quote:
Originally Posted by NoDi522
Посмотреть сообщение
What does cause this ini string error:

PHP код:
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(3710) : error 001expected token")"but found "["
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(3710) : warning 215expression has no effect
C
:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(3710) : error 001expected token";"but found "]"
C:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(3710) : error 029invalid expressionassumed zero
C
:\Users\Dino Covic\Desktop\SAMP Server\gamemodes\Server_Skripta.pwn(3710) : fatal error 107too many error messages on one line 
PHP код:
INI_String("Novac",PlayerInfo[playerid][pNovac],32); // When i remove '32' error is "undefined symbol INI_String" 
Post your enum.

You need to add the value to it, between [].


Re: [INI_String] Error - [XST]O_x - 22.06.2015

Well, this is how INI_String is defined in y_ini:
pawn Код:
INI_String(name[], variable , length );
If you remove the length parameter, you'll get an error. So don't.


Re: [INI_String] Error - NoDi522 - 22.06.2015

PHP код:
enum pInfo
{
    
pPassword,
    
pIP,
    
pSkin,
    
pGodine,
    
pSpol,
    
pScore,
    
pNovac,
    
pMute,
    
pZemlja,
    
pSupporter,
    
pAdministrator,
    
pKod,
    
pVip,
    
pPromoter,
    
Firma,
    
Kuca,
    
Mobitel,
    
pGPS,
    
pRadio,
    
pSat,
    
pGunDozvola,
    
pDriveDozvola,
    
pVozilo,
    
pUbojstva,
    
pZlocini,
    
pLicense,
    
pMotorLicense,
    
pBrodLicense,
    
pKamionLicense,
    
pBankNovac,
    
pBankRacun,
    
pCreditCard,
    
pBanovan,
    
pSmrti,
}; 
You mean like this ?

PHP код:
enum pInfo[]
{
    
pPassword,
    
pIP,
    
pSkin,
    
pGodine,
    
pSpol,
    
pScore,
    
pNovac,
    
pMute,
    
pZemlja,
    
pSupporter,
    
pAdministrator,
    
pKod,
    
pVip,
    
pPromoter,
    
Firma,
    
Kuca,
    
Mobitel,
    
pGPS,
    
pRadio,
    
pSat,
    
pGunDozvola,
    
pDriveDozvola,
    
pVozilo,
    
pUbojstva,
    
pZlocini,
    
pLicense,
    
pMotorLicense,
    
pBrodLicense,
    
pKamionLicense,
    
pBankNovac,
    
pBankRacun,
    
pCreditCard,
    
pBanovan,
    
pSmrti,
}; 



Re: [INI_String] Error - Konstantinos - 22.06.2015

In the enum:
pawn Код:
...
pScore,
pNovac[32],
pMute,
...



Re: [INI_String] Error - NoDi522 - 23.06.2015

thank you.