Crate Error :!
#4

Ooops, my bad.

Try this.

pawn Code:
for(new i; i < rows; i++)
            {
                new crateid, szResult[32], string[128];
                cache_get_field_content(i, "id", szResult, MainPipeline); crateid = strval(szResult);
                if(crateid != 0 && crateid < MAX_CRATES)
                {
                    cache_get_field_content(i, "Active", szResult, MainPipeline); CrateInfo[crateid][crActive] = strval(szResult);
                    cache_get_field_content(i, "CrateX", szResult, MainPipeline); CrateInfo[crateid][crX] = strval(szResult);
                    cache_get_field_content(i, "CrateY", szResult, MainPipeline); CrateInfo[crateid][crY] = strval(szResult);
                    cache_get_field_content(i, "CrateZ", szResult, MainPipeline); CrateInfo[crateid][crZ] = strval(szResult);
                    cache_get_field_content(i, "GunQuantity", szResult, MainPipeline); CrateInfo[crateid][GunQuantity] = strval(szResult);
                    cache_get_field_content(i, "InVehicle", szResult, MainPipeline); CrateInfo[crateid][InVehicle] = strval(szResult);
                    if(CrateInfo[crateid][InVehicle] != INVALID_VEHICLE_ID)
                    {
                        CrateInfo[crateid][crActive] = 0;
                        CrateInfo[crateid][InVehicle] = INVALID_VEHICLE_ID;
                    }
                    if(CrateInfo[crateid][crActive])
                    {
                        CrateInfo[crateid][InVehicle] = INVALID_VEHICLE_ID;
                        CrateInfo[crateid][crObject] = CreateDynamicObject(964,CrateInfo[crateid][crX],CrateInfo[crateid][crY],CrateInfo[crateid][crZ],0.00000000,0.00000000,0.00000000);
                        format(string, sizeof(string), "Serial Number: #%d\n High Grade Materials: %d/50", i, CrateInfo[i][GunQuantity]);
                        CrateInfo[crateid][crLabel] = CreateDynamic3DTextLabel(string, COLOR_ORANGE, CrateInfo[crateid][crX],CrateInfo[crateid][crY],CrateInfo[crateid][crZ]+1, 20.0, _, _, 1, 0, 0, _, 20.0);

                    }
                }  
            }
If this doesn't work, maybe wait until someone with MySQL experience sees this thread and fixes it.
Reply


Messages In This Thread
Crate Error :! - by nguyenquynh - 06.10.2013, 13:38
Re: Crate Error :! - by EiresJason - 06.10.2013, 13:42
Re: Crate Error :! - by nguyenquynh - 06.10.2013, 13:46
Re: Crate Error :! - by EiresJason - 06.10.2013, 13:51
Re: Crate Error :! - by nguyenquynh - 06.10.2013, 13:57
Re: Crate Error :! - by EiresJason - 06.10.2013, 14:07
Re: Crate Error :! - by nguyenquynh - 06.10.2013, 15:02
Re: Crate Error :! - by EiresJason - 06.10.2013, 15:16

Forum Jump:


Users browsing this thread: 1 Guest(s)