31.08.2010, 17:40
I'm trying to do special loop, which iterates every array element. I've got this:
But doesn't iterate last array element:
pawn Код:
new const Skins[] =
{
105, //0
106, //1
107, //2
102, //3
103, //4
104, //5
114, //6
115, //7
116, //8
108, //9
109, //10
110, //11
121, //12
122, //13
124, //14
126, //15
113 //16
};
for(new skin = Skins[0], skin_index = 1; skin_index < sizeof(Skins); skin = Skins[skin_index++])
printf("%d", skin);
print("Text"); //Debug
Quote:
Originally Posted by console
[19:43:20] 105
[19:43:20] 106 [19:43:20] 107 [19:43:20] 102 [19:43:20] 103 [19:43:20] 104 [19:43:20] 114 [19:43:20] 115 [19:43:20] 116 [19:43:20] 108 [19:43:20] 109 [19:43:20] 110 [19:43:20] 121 [19:43:20] 122 [19:43:20] 124 [19:43:20] 126 //there's no 113 :/ [19:43:20] Text |