Regarding Loading
#1

This code crashes my OnGameModeInit. I have no idea what's wrong with it, but any help would be appreciated.

pawn Код:
public LoadVehicleExtras()
{
    printf("Loading Vehicle Extras...");
    new resultline[300];
   
    mysql_query("SELECT * FROM `vehicle_extras` ORDER BY `model` ASC");
    mysql_store_result();
   
    new modelid;
    new tmpmodel;
    new arr[4];
   
    while(mysql_fetch_row(resultline)==1)
    {
        if(!sscanf(resultline, "p<|>a<i>[4]", arr))
        {
            modelid = arr[0];
            if(modelid < 400) continue;
            tmpmodel = modelid-400;
            VehicleExtraInfo[tmpmodel][vxModel] = modelid;
            VehicleExtraInfo[tmpmodel][vxBasePrice] = arr[1];
            VehicleExtraInfo[tmpmodel][vxMaxTrunks] = arr[2];
            VehicleExtraInfo[tmpmodel][vxMaxSold] = arr[3];
        }
        else
        {
            print("Error: There was a problem parsing vehicle extra data! Moving to next result.");
        }
    }
    mysql_free_result();
    return 1;
}
Reply


Messages In This Thread
Regarding Loading - by Antonio [G-RP] - 28.03.2011, 18:50
Re: Regarding Loading - by Donya - 28.03.2011, 18:55
Re: Regarding Loading - by Antonio [G-RP] - 28.03.2011, 22:04
Re: Regarding Loading - by Tee - 28.03.2011, 22:07
Re: Regarding Loading - by Antonio [G-RP] - 28.03.2011, 22:14
Re: Regarding Loading - by [L3th4l] - 28.03.2011, 22:21
Re: Regarding Loading - by Antonio [G-RP] - 28.03.2011, 23:28

Forum Jump:


Users browsing this thread: 1 Guest(s)