JaQQeri

Untitled

May 3rd, 2013
136
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.62 KB | None | 0 0
  1. // This is a comment
  2. // uncomment the line below if you want to write a filterscript
  3. //#define FILTERSCRIPT
  4.  
  5. #include <a_samp>
  6.  
  7. new Timer;
  8.  
  9. forward ChangeColor();
  10.  
  11. public OnFilterScriptInit()
  12. {
  13. Timer = SetTimer("ChangeColor", 80, 1);
  14. return 1;
  15. }
  16.  
  17. public OnFilterScriptExit()
  18. {
  19. KillTimer(Timer);
  20. return 1;
  21. }
  22.  
  23. public ChangeColor()
  24. {
  25. for (new i=0;i<MAX_VEHICLES;i++)
  26. {
  27. new Float:X,Float:Y,Float:Z;
  28. GetVehiclePos(i, X,Y,Z);
  29. if (X != 0.0)
  30. {
  31. new color1 = random(255);
  32. new color2 = random(255);
  33. ChangeVehicleColor(i, color1, color2);
  34. }
  35. }
  36. }
Advertisement
Add Comment
Please, Sign In to add comment