TahirUcar

SA-MP Komuta Timer Ekleme

Feb 5th, 2017
131
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.96 KB | None | 0 0
  1. #include <a_samp>
  2. #include <zcmd>
  3. #include <sscanf2>
  4.  
  5. #if defined FILTERSCRIPT
  6.  
  7. public OnFilterScriptInit()
  8. {
  9.     print("\n--------------------------------------");
  10.     print(" Blank Filterscript by your name here");
  11.     print("--------------------------------------\n");
  12.     return 1;
  13. }
  14.  
  15. public OnFilterScriptExit()
  16. {
  17.     return 1;
  18. }
  19.  
  20. #else
  21. #endif
  22.  
  23. new canveri[MAX_PLAYERS];
  24. new zaman[MAX_PLAYERS];
  25.  
  26. forward Can(playerid);
  27. public Can(playerid)
  28. {
  29.     canveri[playerid] = 0;
  30.     return 1;
  31. }
  32.  
  33.  
  34. CMD:can(playerid, params[])
  35. {
  36.     if(canveri[playerid] == 1)  return SendClientMessage(playerid,-1,"{00FFDD}Hata: {999999}Bu komutu tekrardan kullanabilmek için {00FFDD}30 sn {999999}beklemelisin");
  37.     canveri[playerid] = 1;
  38.     zaman[playerid] = SetTimerEx("CanKomutu", 30000, false, "d", playerid); // 1 sn = 10000
  39.     SetPlayerHealth(playerid, 100);
  40.     SendClientMessage(playerid,-1,"{00FFDD}Bilgi: {999999}Canınızı başarıyla yenilediniz.");
  41.     return 1;
  42. }
Advertisement
Add Comment
Please, Sign In to add comment