26.09.2013, 10:20
I have narrowed it down to this section of code that causes the crash. Any further help would be great
Код:
stock CreatePlayerVehicle(playerid, playervehicleid, modelid, Float: x, Float: y, Float: z, Float: angle, color1, color2, price) { if(PlayerVehicleInfo[playerid][playervehicleid][pvId] == INVALID_PLAYER_VEHICLE_ID) { PlayerCars++; PlayerVehicleInfo[playerid][playervehicleid][pvModelId] = modelid; PlayerVehicleInfo[playerid][playervehicleid][pvPosX] = x; PlayerVehicleInfo[playerid][playervehicleid][pvPosY] = y; PlayerVehicleInfo[playerid][playervehicleid][pvPosZ] = z; PlayerVehicleInfo[playerid][playervehicleid][pvPosAngle] = angle; PlayerVehicleInfo[playerid][playervehicleid][pvColor1] = color1; PlayerVehicleInfo[playerid][playervehicleid][pvColor2] = color2; PlayerVehicleInfo[playerid][playervehicleid][pvPark] = 1; PlayerVehicleInfo[playerid][playervehicleid][pvPrice] = price; PlayerVehicleInfo[playerid][playervehicleid][pvFuel] = 100.0; PlayerVehicleInfo[playerid][playervehicleid][pvImpounded] = 0; for(new m = 0; m < MAX_MODS; m++) { PlayerVehicleInfo[playerid][playervehicleid][pvMods][m] = 0; } new carcreated = CreateVehicle(modelid,x,y,z,angle,color1,color2,-1); PlayerVehicleInfo[playerid][playervehicleid][pvId] = carcreated; //SetVehicleNumberPlate(carcreated, PlayerVehicleInfo[playerid][playervehicleid][pvNumberPlate]); return carcreated; } return INVALID_PLAYER_VEHICLE_ID; }