Advertisement
cone97

Untitled

Jun 23rd, 2017
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.68 KB | None | 0 0
  1. YCMD:rentparkiraj(playerid, params[], help)
  2. {
  3. #pragma unused params
  4. #pragma unused help
  5. new Float:motorent_Pos[4],i;
  6. if(UlogovanProvera[playerid] == 0) return SCM(playerid, -1, ""CRVENA"WARNING: "BELA"Morate se ulogovati da bi ste koristili ovu komandu.");
  7. if(PlayerInfo[playerid][pAdmin] < 4) return SCM(playerid, -1, ""CRVENA"WARNING: "BELA"Ne mozete koristiti ovu komandu jer niste Administrator.");
  8. if(!IsPlayerInAnyVehicle(playerid)) return SCM(playerid,-1,""CRVENA" "BELA"Ne mozete koristiti ovu komandu jer se ne nalazite na motoru.");
  9. for(new rent_id = 0; rent_id < sizeof(Rent_Info); rent_id++)
  10. {
  11. if(Rent_Info[rent_id][rent_VoziloID] == GetPlayerVehicleID(playerid))
  12. {
  13. GetVehiclePos(Rent_Info[i][rent_ModelID], motorent_Pos[0], motorent_Pos[1], motorent_Pos[2]);
  14. GetVehicleZAngle(Rent_Info[i][rent_ModelID], motorent_Pos[3]);
  15. Rent_Info[i][rent_Pos][ 0 ] = motorent_Pos[0];
  16. Rent_Info[i][rent_Pos][ 1 ] = motorent_Pos[1];
  17. Rent_Info[i][rent_Pos][ 2 ] = motorent_Pos[2];
  18. Rent_Info[i][rent_Pos][ 3 ] = motorent_Pos[3];
  19. DestroyVehicle(Rent_Info[i][rent_ModelID]);
  20. Rent_Info[i][rent_VoziloID] = CreateVehicle(Rent_Info[rent_id][rent_ModelID], Rent_Info[rent_id][rent_Pos][0], Rent_Info[rent_id][rent_Pos][1], Rent_Info[rent_id][rent_Pos][2], Rent_Info[rent_id][rent_Pos][3], Rent_Info[rent_id][rent_Boja1], Rent_Info[rent_id][rent_Boja2], 3000);
  21. SCM(playerid,-1, ""CRVENA"INFO: "BELA"Uspesno ste parkirali motor.");
  22. Sacuvaj_Rent(rent_id);
  23. SetVehicleToRespawn(GetPlayerVehicleID(playerid));
  24. }
  25. }
  26. return 1;
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement