Advertisement
Guest User

Untitled

a guest
Jun 5th, 2017
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.31 KB | None | 0 0
  1. public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
  2. {
  3. if(vehicleid == PoliceVehicle[1] || PoliceVehicle[2] || PoliceVehicle[3] || PoliceVehicle[4] || PoliceVehicle[5] || PoliceVehicle[6] || PoliceVehicle[7] || PoliceVehicle[8] || PoliceVehicle[9])
  4. {
  5. if(PlayerInfo[playerid][pFaction] != 1)
  6. {
  7. SetTimerEx("RemoveFromVehicle", 1000, false, "i", playerid);
  8. }
  9. else return InCopCar[playerid] = 1;
  10. }
  11. else return InCopCar[playerid] = 0;
  12.  
  13. if(vehicleid == ParamedicVehicle[1] || ParamedicVehicle[1] || ParamedicVehicle[1] || ParamedicVehicle[1] || ParamedicVehicle[1] || ParamedicVehicle[1] || ParamedicVehicle[1] || ParamedicVehicle[1] || ParamedicVehicle[1])
  14. {
  15. if(PlayerInfo[playerid][pFaction] != 2)
  16. {
  17. SetTimerEx("RemoveFromVehicle", 1000, false, "i", playerid);
  18. }
  19. else return InParamedicCar[playerid] = 1;
  20. }
  21. else return InParamedicCar[playerid] = 0;
  22.  
  23. return 1;
  24. }
  25.  
  26. forward RemoveFromVehicle(playerid);
  27. public RemoveFromVehicle(playerid)
  28. {
  29. new Float:x, Float:y, Float: z;
  30. GetPlayerPos(playerid, x, y, z);
  31. SetPlayerPos(playerid, x, y, z+1);
  32. RemovePlayerFromVehicle(playerid);
  33. GameTextForPlayer(playerid, "~r~Nu esti autorizat sa conduci aceasta masina!", 1000, 3);
  34. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement