View Single Post
Old 11/03/2011, 09:50 AM   #77
Zh3r0
High-roller
 
Join Date: Mar 2008
Posts: 4,512
Reputation: 398
Default Re: Y_Ini - Let's do it!

Quote:
Originally Posted by Riddick94 View Post
Code:
C:\Documents and Settings\Kakarotto\Pulpit\Sa-Mp Serwer 0.3c\gamemodes\pes.pwn(2159) : error 022: must be lvalue (non-constant)
C:\Documents and Settings\Kakarotto\Pulpit\Sa-Mp Serwer 0.3c\gamemodes\pes.pwn(2162) : error 022: must be lvalue (non-constant)
Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase


2 Errors.
pawn Code:
foreach2(w, MAX_WEAPON_SLOTS)
    {
        new string[32];
        format(string, sizeof(string), "Weapon_%d", w);
        INI_Int(string, strval(PlayerInfo[playerid][Weapons][w]));
       
        format(string, sizeof(string), "Ammo_%d", w);
        INI_Int(string, strval(PlayerInfo[playerid][Ammo][w]));
        GivePlayerWeaponEx(playerid, PlayerInfo[playerid][Weapons][w], PlayerInfo[playerid][Ammo][w]);
    }
This is why i mostly use INI_ParseFile.
Wait a minute or more, I'm writing the function. AFTER I EAT
__________________
Zh3r0 is offline