enum HOUSE { naam[128], Float:x, Float:y, Float:z, Float:angle } new Autos[][HOUSE] = { {"Blank", 1000.0000, 1000.0000, 1000.0000, 0.0000}, {"Huis1Auto", 319.3104,-127.6115,1.8452,269.9319}, // huis 1auto {"Huis2Auto", 319.1501,-86.5001,1.8718,270.1909}, // huis2auto {"Huis3Auto", 287.8148,-56.0016,1.2858,180.8278}, // huis3auto {"Huis4Auto", 278.0771,-57.9574,1.2846,179.3597}, // huis4atuo {"Huis5Auto", 245.8908,-85.4922,1.7829,90.0099}, // huis5atuo {"Huis6Auto", 246.8221,-127.3508,1.9527,89.6495},// huis6atuo {"Huis7Auto", 347.9392,-86.8232,1.0762,88.8303}, // huis7atuo {"Huis8Auto", 334.1310,-57.0428,1.2225,90.7807}, // huis8auto {"Huis9Auto", 340.0226,69.7249,3.6209,119.7046}, // huis9auto {"Huis10Auto", 328.4067,28.2995,6.0838,204.9715},// huis10auto {"Huis11Auto", 325.2183,61.0262,3.0980,228.0177}, // huis11auto {"Huis12Auto", 311.5359,46.6569,2.5756,205.5373}, // huis12auto {"Huis13Auto", 290.7342,38.9044,2.2759,200.9525}, // huis13auto {"Huis14Auto", 306.2288,17.4394,4.0454,204.0326}, // huis14auto {"Caravan1Auto", 260.7227,-264.1146,1.2858,101.4284}, // caravan 1auto {"Caravan2Auto", 266.7806,-278.8409,1.2848,61.0982}, // caravan 2auto {"Caravan3Auto", 257.3769,-311.5176,1.3065,74.6087}, // caravan2atuo {"Caravan4Auto", 229.5779,-312.5587,1.3110,26.9298}// caravan4auto }; new VehIDs[sizeof(Autos)]; public OnFilterScriptInit() { if(!dini_Exists("BlueberryCars.txt")) { dini_Create("BlueberryCars.txt") } for(new i = 1; i <= sizeof(Autos); i++) { if(dini_Int("BlueberryCars.txt", Autos[i][naam]) != 0) { new modelid = dini_Int("BlueberryCars", Autos[i][naam]); VehIDs[i] = CreateVehicle(modelid, Autos[i][x], Autos[i][y], Autos[i][z], Autos[i][angle], CARGREY, CARGREY, 1000); } else { VehIDs[i] = -1; } } return 1; } public OnPlayerSpawn(playerid) { new pName[24]; GetPlayerName(playerid, pName, sizeof(pName)); new spawnid = dini_Int(udb_encode(pName), "spawn"); for(new h = 0; h <= sizeof(Autos); h++) { if(h != spawnid && VehIDs[h] != -1) { SetVehicleParamsForPlayer(VehIDs[h], playerid, true, true); } } return 1; }
Originally Posted by gamer_Z
comment this out and check if it then crashes? maybe something others is causing the crash.
|
public OnPlayerSpawn(playerid) { new pName[24]; GetPlayerName(playerid, pName, sizeof(pName)); new spawnid = dini_Int(udb_encode(pName), "spawn"); for(new h = 0; h <= sizeof(Autos); h++) { if(h != spawnid && VehIDs[h] != -1) { SetVehicleParamsForPlayer(VehIDs[h], playerid, true, true); } } return 1; }
new modelid = dini_Int("BlueberryCars", Autos[i][naam]);
//Shouldn't this be...
new modelid = dini_Int("BlueberryCars.txt", Autos[i][naam]);