Advertisement
Guest User

DavidSparks - Easy Vehicle Fixing.

a guest
Jul 9th, 2014
359
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.06 KB | None | 0 0
  1. // Easy car fix system - Made by DavidSparks.
  2.  
  3. #include <a_samp>
  4.  
  5. #if defined FILTERSCRIPT
  6. #define COLOR_GREY 0xAFAFAFAA
  7.  
  8. public OnFilterScriptInit()
  9. {
  10. print("\n--------------------------------------");
  11. print(" Blank Filterscript by your name here");
  12. print("--------------------------------------\n");
  13. return 1;
  14. }
  15.  
  16. public OnFilterScriptExit()
  17. {
  18. return 1;
  19. }
  20.  
  21. CMD:fix(playerid, params[])
  22. {
  23. if(IsPlayerConnected(playerid)) {
  24. if(IsPlayerInAnyVehicle(playerid)) {
  25. RepairVehicle(GetPlayerVehicleID(playerid));
  26. SendClientMessageEx(playerid, COLOR_GREY, " Vehicle Fixed!");
  27. }
  28. }
  29. return 1;
  30. }
  31.  
  32. CMD:fixall(playerid, params[])
  33. {
  34. if(IsPlayerConnected(playerid)) {
  35. if(IsPlayerAdmin(playerid))
  36. for(new v = 0; v < MAX_VEHICLES; v++) {
  37. RepairVehicle(v);
  38. }
  39. SendClientMessageEx(playerid, COLOR_GREY, " All vehicles fixed!");
  40. }
  41. else
  42. {
  43. SendClientMessageEx(playerid, COLOR_GREY, " You are not authorized to do this!");
  44. return 1;
  45. }
  46.  
  47. #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement