Jump to content

Diendo

Membru
  • Posts

    13
  • Joined

  • Last visited

    Never

Diendo's Achievements

Apprentice

Apprentice (3/14)

  • First Post
  • Collaborator
  • Conversation Starter
  • Week One Done
  • One Month Later

Recent Badges

0

Reputation

  1. public LoadCar() { new arrCoords[13][64]; new strFromFile2[256]; new File: file = fopen("cars.cfg", io_read); if (file) { new idx = 225; while (idx < sizeof(CarInfo)) { fread(file, strFromFile2); split(strFromFile2, arrCoords, ','); CarInfo[idx][cModel] = strval(arrCoords[0]); CarInfo[idx][cLocationx] = floatstr(arrCoords[1]); CarInfo[idx][cLocationy] = floatstr(arrCoords[2]); CarInfo[idx][cLocationz] = floatstr(arrCoords[3]); CarInfo[idx][cAngle] = floatstr(arrCoords[4]); CarInfo[idx][cColorOne] = strval(arrCoords[5]); CarInfo[idx][cColorTwo] = strval(arrCoords[6]); strmid(CarInfo[idx][cOwner], arrCoords[7], 0, strlen(arrCoords[7]), 255); strmid(CarInfo[idx][cDescription], arrCoords[8], 0, strlen(arrCoords[8]), 255); CarInfo[idx][cValue] = strval(arrCoords[9]); CarInfo[idx][cLicense] = strval(arrCoords[10]); CarInfo[idx][cOwned] = strval(arrCoords[11]); CarInfo[idx][cLock] = strval(arrCoords[12]); printf("CarInfo: %d Owner:%s LicensePlate %s",idx,CarInfo[idx][cOwner],CarInfo[idx][cLicense]); idx++; } } return 1; } public SaveCarCoords() { new idx; new File: file2; while (idx < sizeof(CarInfo)) { new coordsstring[256]; format(coordsstring, sizeof(coordsstring), "%d|%f|%f|%f|%f|%d|%d\n", CarInfo[idx][cModel], CarInfo[idx][cLocationx], CarInfo[idx][cLocationy], CarInfo[idx][cLocationz], CarInfo[idx][cAngle], CarInfo[idx][cColorOne], CarInfo[idx][cColorTwo]); if(idx == 225) { file2 = fopen("cars.cfg", io_write); } else { file2 = fopen("cars.cfg", io_append); } fwrite(file2, coordsstring); idx++; fclose(file2); } return 1; } Uitati
  2. Dupa tutorialul tau mam luat dar nu imi merg toate masinile
  3. Am LoadCars SaveCars si carInfo.Mie imi merg 43 de masini personale restul nu imi merg (mi se sterg din car.ini)si nu stiu de ce.
  4. Salutare!Din pacate am numai probleme cu sistemul de masini si as vrea sa ma ajutati cu aceasta:am adaugat in cars.ini niste masini personale am modificat in gm-idurile de la IsAnOwnableCar pana aici bine de aici apare problema,cand pornesc serverul, din 70 de masini personale se sterg aproape 27 de masini din cars.ini si nu stiu ca sa fac sa le bag si pe acelea in server Multumesc anicipat
  5. am introdus niste masini personale pe server si sa reparat.Dar acum cand dau /apark nu imi mai apare masina
  6. Am facut cum ai zis Dakker dar tot la fel Unknown Comand Mai stii vreo solutie?
  7. Los Angeles Roleplay De ce?
  8. error 017:undefined symbol "IsPlayerInCar" warning 215: expression has no effect error 001: expected token: ";", but found "]" error 029: invalid expression, assumed zero fatal error 107: too many error messages on one line
  9. Alta erroare:error 004: function "OnPlayerUpdateEx" is not implemented
  10. Eroarea:(24640) : error 017: undefined symbol "OnPlayerUpdateEx" Linia:OnPlayerUpdateEx(playerid);
  11. Tot la fel:Server:Unknown Comand. Apropo mia dat eroare si am modificat OnPlayerUpdateEX(playerid); cu OnPlayerUpdate(playerid);
  12. Salutare as avea o problema.Deci am creeat comanda /apark dar cand intru intr-o masina imi zice Server:Unknown Comand iar cand ies din masina si dai /apark imi merge. Uitati comanda: if(strcmp(cmd, "/apark", true) == 0) { if(IsPlayerConnected(playerid)) { new Float:x,Float:y,Float:z; new Float:a; new carid; carid = GetPlayerVehicleID(playerid); GetPlayerName(playerid, playername, sizeof(playername)); GetVehiclePos(carid, x, y, z); // GetPlayerFacingAngle(playerid, a); GetVehicleZAngle(carid, a); if(PlayerInfo[playerid][pAdmin] >= 3) { CarInfo[carid][cLocationx] = x; CarInfo[carid][cLocationy] = y; CarInfo[carid][cLocationz] = z; CarInfo[carid][cAngle] = a; format(string, sizeof(string), "~n~ You have parked your car in this location. ~n~"); GameTextForPlayer(playerid, "You have parked this car in this position. It will respawn here.", 10000, 3); OnPropUpdate(); OnPlayerUpdate(playerid); DestroyVehicle(carid); CreateVehicle(CarInfo[carid][cModel],CarInfo[carid][cLocationx],CarInfo[carid][cLocationy],CarInfo[carid][cLocationz]+1.0,CarInfo[carid][cAngle],CarInfo[carid][cColorOne],CarInfo[carid][cColorTwo],60000); return 1; } else { SendClientMessage(playerid, COLOR_GREY, " You are not authorized to use that command !"); return 1; } } return 1; } Multumesc anticipat
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.