Advertisement
Guest User

Untitled

a guest
Dec 26th, 2015
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.81 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. #include <streamer>
  7.  
  8. #if defined FILTERSCRIPT
  9.  
  10. new MyTimer[MAX_PLAYERS];//gang 1
  11. new Count=60;//gang 1
  12.  
  13. public OnFilterScriptInit()
  14. {
  15. print("\n--------------------------------------");
  16. print(" Blank Filterscript by your name here");
  17. print("--------------------------------------\n");
  18. return 1;
  19. }
  20.  
  21. public OnFilterScriptExit()
  22. {
  23. return 1;
  24. }
  25.  
  26. #else
  27.  
  28. main()
  29. {
  30. print("\n----------------------------------");
  31. print(" Blank Gamemode by your name here");
  32. print("----------------------------------\n");
  33. }
  34.  
  35. #endif
  36.  
  37. public OnGameModeInit()
  38. {
  39. // Don't use these lines if it's a filterscript
  40. SetGameModeText("Blank Script");
  41. AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
  42. Count=60;
  43. return 1;
  44. }
  45.  
  46. public OnGameModeExit()
  47. {
  48. return 1;
  49. }
  50.  
  51. public OnPlayerRequestClass(playerid, classid)
  52. {
  53. SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
  54. SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
  55. SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
  56. return 1;
  57. }
  58.  
  59. public OnPlayerCommandText(playerid, cmdtext[])
  60. {
  61. if(strcmp("/capture", cmdtext, true, 10) == 0)
  62. {
  63. if(Count <= 59) return SendClientMessage(playerid, 0xFFFFFF, "ERROR:This gang is already under capture.");
  64. Count = 60;
  65. SendClientMessage(playerid,0xfff000,"+1 secondo");
  66. KillTimer(MyTimer[playerid]);
  67. MyTimer[playerid] = SetTimerEx("TestFunction", 1000, 1, "i", playerid);
  68. }
  69. return 1;
  70. }
  71. return 0;
  72. }
  73.  
  74. forward TestFunction(playerid);//upc
  75. public TestFunction(playerid)//upc
  76. {
  77. Count--;
  78. if(Count == 0)
  79. {
  80. SendClientMessage(playerid, 0xff00000, "+ 1 minuto.");
  81. KillTimer(MyTimer[playerid]);
  82. Count = 60;
  83. }
  84. }
  85. return 1;
  86. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement