03.12.2011, 15:10
Edit: sorry, I haved fixed it myself by removing the size of the second dimension:
I have this code:
The first cell of the last dimension should always be X but it isn't working. Am I missing anything?
This code:
Prints:
I believe that it has to print:
pawn Код:
new const Float:Bases[][][4]
pawn Код:
new const Float:Bases[][2][4] =
{
{
{2489.9683, -1666.2428, 13.3438, 90.0},
{2301.8442, -1639.3610, 14.6308, 180.0}
}
};
This code:
pawn Код:
main()
{
for(new i = 0; i != sizeof(Bases); i++)
{
for(new j = 0; j != 2; j++)
{
printf("%.4f, %.4f, %.4f, %.4f", Bases[i][j][0], Bases[i][j][1], Bases[i][j][2], Bases[i][j][3]);
}
}
}
Код:
[11:43:28] 13.3437, 90.0000, 2301.8442, -1639.3609 [11:43:28] 14.6308, 180.0000, 0.0000, 0.0000
Код:
2489.9683, -1666.2428, 13.3438, 90.0 2301.8442, -1639.3610, 14.6308, 180.0