Advertisement
garfield

[COD]: adicionando Adicionando a função GetMaxVehicles()

May 1st, 2012
273
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 1.19 KB | None | 0 0
  1. // SuYaNw - Garfield xD
  2.  
  3. new
  4.     Veiculos = -1
  5. ;
  6.  
  7. stock sDestroyVehicle(vehicleid)
  8. {
  9.     if(GetVehicleModel(vehicleid)) return false;
  10.     Veiculos--;
  11.     return CallRemoteFunction("DestroyVehicle", "i", vehicleid);
  12. }
  13.  
  14. stock sAddStaticVehicle(modelid, Float:spawn_x, Float:spawn_y, Float:spawn_z, Float:angle, color1, color2)
  15. {
  16.     Veiculos++;
  17.     return AddStaticVehicle(modelid, Float:spawn_x, Float:spawn_y, Float:spawn_z, Float:angle, color1, color2);
  18. }
  19.  
  20. stock sAddStaticVehicleEx(modelid, Float:spawn_x, Float:spawn_y, Float:spawn_z, Float:angle, color1, color2, respawn_delay)
  21. {
  22.     Veiculos++;
  23.     return AddStaticVehicleEx(modelid, Float:spawn_x, Float:spawn_y, Float:spawn_z, Float:angle, color1, color2, respawn_delay);
  24. }
  25.  
  26. stock sCreateVehicle(modelid, Float:x, Float:y, Float:z, Float:angle, color1, color2, respawn_delay)
  27. {
  28.     Veiculos++;
  29.     return CreateVehicle(modelid, Float:x, Float:y, Float:z, Float:angle, color1, color2, respawn_delay);
  30. }
  31.  
  32.  
  33. #define DestroyVehicle      sDestroyVehicle
  34. #define AddStaticVehicle    sAddStaticVehicle
  35. #define AddStaticVehicleEx  sAddStaticVehicleEx
  36. #define CreateVehicle       sCreateVehicle
  37. #define GetMaxVehicles()    Veiculos
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement