Weird problem with ints in an array
#1

I'm trying to store data for vehicles.

This is my array:

pawn Код:
enum VEnum
{
    locked,
    lastDriver,
    type
};
new VehStats[MAX_VEHICLES][VEnum];

pawn Код:
for(new i = 0; i < MAX_VEHICLES; i++)
{
      VehStats[i][locked] = 0;
}
printf("LOCKED: %i", VehStats[1][locked]); // Prints LOCKED: 1150318466
Right after this loop I print the value of VehStats[vehicleid][locked] and it has somehow become 1150318466.


EDIT:

http://pastebin.com/NDzhE2RT I'm having the problem in this include. line 158 does print VehStats[vehicleid][locked] correctly but line 164 doesn't.
Reply


Messages In This Thread
Weird problem with ints in an array - by klimgorilla - 21.04.2014, 18:06
Re: Weird problem with ints in an array - by PrinceKumar - 21.04.2014, 18:18
Re: Weird problem with ints in an array - by klimgorilla - 21.04.2014, 18:21
Re: Weird problem with ints in an array - by PrinceKumar - 21.04.2014, 18:23
Re: Weird problem with ints in an array - by klimgorilla - 21.04.2014, 18:28
Re: Weird problem with ints in an array - by Djole1337 - 21.04.2014, 18:35
Re: Weird problem with ints in an array - by klimgorilla - 21.04.2014, 18:55

Forum Jump:


Users browsing this thread: 1 Guest(s)