Loading/Using multiple values
#1

I have this code;
pawn Код:
enum aaaa
{
    Float:test[3]
}
new tesst[][aaaa];

for(new i = 0; i < PicksCount; i++)
        {
            format(Pickstr[0], 128, "map/racepickup[%d]/@type", i);
            format(Pickstr[1], 128, "map/racepickup[%d]/@posX", i);
            format(Pickstr[2], 128, "map/racepickup[%d]/@posY", i);
            format(Pickstr[3], 128, "map/racepickup[%d]/@posZ", i);
            for(new a = 0; a < sizeof(tesst[]); a++)
            {
                tesst[a][test][0] = xml_get_float(MAP, Pickstr[1]);
                tesst[a][test][1] = xml_get_float(MAP, Pickstr[2]);
                tesst[a][test][2] = xml_get_float(MAP, Pickstr[3]);
//              printf("%0.4f, %0.4f, %0.4f", tesst[a][test][0], tesst[a][test][1], tesst[a][test][2]);
All values from xml_get_float are saved into tesst[a][test][0/1/2] variables perfectly(around 60 values). But when I wanted to use the variables;

pawn Код:
public PickUps() //SetTimer
{
    for(new a = 0; a < sizeof(PickAmount); a++)
    {
//        printf("%0.4f, %0.4f, %0.4f", tesst[a][test][0], tesst[a][test][1], tesst[a][test][2]);
    }
    return 1;
}
It only loads 1 value instead of 60~.
Reply


Messages In This Thread
Loading/Using multiple values - by newbienoob - 02.12.2013, 05:56
Re: Loading/Using multiple values - by Voxel - 02.12.2013, 06:37
Re: Loading/Using multiple values - by newbienoob - 02.12.2013, 07:05
Re: Loading/Using multiple values - by Kyosaur - 02.12.2013, 07:11
Re: Loading/Using multiple values - by newbienoob - 02.12.2013, 07:52

Forum Jump:


Users browsing this thread: 2 Guest(s)