Advertisement
DiGiTaL_AnGeL

FSevent - RP

Dec 12th, 2012
552
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 21.37 KB | None | 0 0
  1. /* DDDDD      @  GGGGGGGGGG  @  TTTTTTTTTTTTTT  AAAAAAAA LL              AAAAAAAA NN    NN GGGGGGGGGG EEEEEEEE LL
  2.    DDDDDDD   III GGGGGGGGGG III TTTTTT  TTTTTT  AA    AA LL              AA    AA NN    NN GGGGGGGGGG EE       LL
  3.    DD    DD  I I GG         I I      T  T       AA    AA LL              AA    AA NN    NN GG         EE       LL
  4.    DD    DDD I I GG         I I      T  T       AA    AA LL              AA    AA NNNN  NN GG         EE       LL
  5.    DD    DDD I I GG   GGGGG I I      T  T       AAAAAAAA LL              AAAAAAAA NN NN NN GG   GGGGG EEEEEE   LL
  6.    DD    DD  I I GG      GG I I      T  T       AA    AA LL              AA    AA NN  NNNN GG      GG EE       LL
  7.    DDDDDDD   I I GGGGGGG GG I I      T  T       AA    AA LL              AA    AA NN    NN GGGGGGG GG EE       LL
  8.    DDDDD     III GGGGGGGGGG III      TTTT       AA    AA LLLLLLLLL       AA    AA NN    NN GGGGGGGGGG EEEEEEEE LLLLLLLLL
  9.  
  10. ==============================================Fy Snow event - RP version ===============================================
  11.  
  12.     Fs made by me(DiGitaL AnGeL) Why? Cause I was boring. The map is not made by me, is made by Miron Dorin(well he told me that he made it). I asked
  13. for his permission to do a FS on his map, and he said it's OK. This is the version for RP versions. Why? Well after you die, you won't respawn at the
  14. event, you'll respawn at your normal spawn. There is also a cmds that you won't find on the DM version : /startevent & /fsevent. Why? Cause in a dm,
  15. you can always tp to the event, and there is no starting, the event is always on. ;)
  16.     P.S. If you want to recompile the FS, you need DiGiTaL Colors, made by me. Or just change the colors code with others defined by you.
  17.     Credits to ~> DiGitaL AnGeL -> For making the FS + DiGitaL Colors
  18.                ~> Miron Dorin   -> For making the map
  19.                ~> Y_Less        -> For YCMD
  20.                ~> Kalcor        -> For SA:MP
  21.                ~> spookie       -> For the PAWN Compiler GUI
  22.                
  23.     Commands ~> /fsevent --> Enables/disables the event
  24.              ~> /startevent --> Starts the event(unfreezes the players)
  25.              ~> /joinfsevent --> Allows you to choose a team for the event(CT or Terrorists)
  26.              ~> /snowoff --> Disables the snow
  27.              ~> /snow --> Enables the snow
  28.              ~> /leavefs --> Respawns you, but you loose $500.
  29.                                                                 DiGiTaL_AnGeL 2012(tm)                                          */
  30. #define FILTERSCRIPT
  31. //______________________________INCLUDES______________________________________________
  32. #include <a_samp>
  33. #include <YSI\y_commands>
  34. #include <digital_colors>
  35. //_______________________________DEFINES_______________________________________
  36. #define SCM SendClientMessage
  37. #define PTP PlayerToPoint
  38. #define GPN GetPlayerName(playerid, sendername, sizeof(sendername))
  39. #define SCMTA SendClientMessageToAll
  40. #define TSelect 364
  41. #define Help 365
  42. //________________________NEW________________________________
  43. new fsevent = 0;
  44. new snow[3];
  45. new destroyedsnow = 0;
  46. new ct = 0;
  47. new terro = 0;
  48. //____________________FORWARDS_____________________________
  49. forward EC3();
  50. forward EC2();
  51. forward EC1();
  52. forward ES();
  53. //_________________________________________________________
  54. #if defined FILTERSCRIPT
  55.  
  56. public OnFilterScriptInit()
  57. {
  58.     snow[1] = CreateObject(18864, -164.14, 1418.76, 1119.20,   47.00, -91.00, 69.00);
  59.     snow[2] = CreateObject(18864, -148.04, 1411.10, 1119.20,   47.00, -91.00, 69.00);
  60.     CreateObject(8664, -249.62, 1403.76, 1131.98,   0.00, 0.00, 0.00);
  61.     CreateObject(8664, -249.62, 1403.76, 1131.98,   0.00, 0.00, 0.00);
  62.     CreateObject(3915, -166.23, 1431.95, 1132.33,   0.00, 0.00, 359.98);
  63.     CreateObject(3915, -166.29, 1390.17, 1132.33,   0.00, 0.00, 359.98);
  64.     CreateObject(3915, -219.29, 1325.08, 1132.33,   0.00, 0.00, 269.08);
  65.     CreateObject(3915, -166.29, 1348.73, 1132.33,   0.00, 0.00, 359.98);
  66.     CreateObject(3915, -260.81, 1325.57, 1132.33,   0.00, 0.00, 269.08);
  67.     CreateObject(3915, -292.01, 1386.37, 1132.33,   0.00, 0.00, 180.23);
  68.     CreateObject(3915, -302.68, 1325.94, 1132.33,   0.00, 0.00, 269.08);
  69.     CreateObject(3915, -292.15, 1428.38, 1132.33,   0.00, 0.00, 180.23);
  70.     CreateObject(3915, -292.05, 1344.85, 1132.35,   0.00, 0.00, 180.23);
  71.     CreateObject(3095, -199.14, 1357.15, 1131.30,   0.00, 90.00, 0.00);
  72.     CreateObject(3095, -216.23, 1361.94, 1136.66,   89.54, 6.00, 264.75);
  73.     CreateObject(3095, -203.24, 1361.68, 1140.66,   0.00, 0.00, 0.52);
  74.     CreateObject(3095, -203.30, 1370.63, 1140.71,   0.00, 0.00, 0.52);
  75.     CreateObject(3095, -212.30, 1370.61, 1140.71,   0.00, 0.00, 0.52);
  76.     CreateObject(3095, -212.15, 1361.86, 1140.69,   0.00, 0.00, 0.52);
  77.     CreateObject(3095, -212.27, 1374.89, 1136.66,   89.54, 6.00, 174.31);
  78.     CreateObject(3095, -216.36, 1370.60, 1136.66,   89.54, 6.00, 264.75);
  79.     CreateObject(3095, -203.26, 1374.97, 1136.66,   89.54, 6.00, 174.31);
  80.     CreateObject(3095, -199.08, 1370.83, 1136.66,   89.54, 6.00, 85.43);
  81.     CreateObject(3095, -198.85, 1361.81, 1136.66,   89.54, 6.00, 85.43);
  82.     CreateObject(3095, -202.77, 1357.69, 1136.66,   89.54, 6.00, 353.77);
  83.     CreateObject(3095, -211.80, 1357.73, 1136.66,   89.54, 6.00, 353.77);
  84.     CreateObject(3917, -205.22, 1382.71, 1115.81,   0.00, 270.00, 181.50);
  85.     CreateObject(3917, -205.15, 1378.79, 1115.81,   0.00, 270.00, 181.50);
  86.     CreateObject(3917, -220.25, 1369.06, 1115.81,   0.00, 270.00, 270.25);
  87.     CreateObject(3917, -224.42, 1369.01, 1115.81,   0.00, 270.00, 270.25);
  88.     CreateObject(3917, -210.27, 1353.62, 1115.81,   0.00, 270.00, 0.75);
  89.     CreateObject(3917, -210.24, 1349.84, 1115.81,   0.00, 270.00, 0.75);
  90.     CreateObject(3917, -194.64, 1363.52, 1115.81,   0.00, 270.00, 89.75);
  91.     CreateObject(3917, -190.37, 1363.49, 1115.81,   0.00, 270.00, 89.74);
  92.     CreateObject(3095, -199.19, 1391.67, 1136.66,   89.54, 6.00, 83.43);
  93.     CreateObject(3095, -199.12, 1400.57, 1136.66,   89.54, 6.00, 83.42);
  94.     CreateObject(3095, -203.64, 1391.61, 1140.71,   0.00, 0.00, 0.52);
  95.     CreateObject(3095, -203.71, 1400.52, 1140.71,   0.00, 0.00, 0.52);
  96.     CreateObject(3095, -212.72, 1400.48, 1140.71,   0.00, 0.00, 0.52);
  97.     CreateObject(3095, -212.63, 1391.54, 1140.68,   0.00, 0.00, 0.52);
  98.     CreateObject(3095, -203.21, 1387.41, 1136.66,   89.54, 6.00, 354.67);
  99.     CreateObject(3095, -212.25, 1387.33, 1136.66,   89.54, 6.00, 354.67);
  100.     CreateObject(3095, -216.90, 1391.27, 1136.66,   89.54, 6.00, 264.92);
  101.     CreateObject(3095, -217.05, 1400.27, 1136.66,   89.54, 6.00, 264.92);
  102.     CreateObject(3095, -213.13, 1404.45, 1136.66,   89.54, 6.00, 174.92);
  103.     CreateObject(3095, -203.94, 1404.60, 1136.66,   89.54, 6.00, 174.91);
  104.     CreateObject(3917, -204.90, 1408.50, 1115.81,   0.00, 270.00, 179.50);
  105.     CreateObject(3917, -204.81, 1412.58, 1115.81,   0.00, 270.00, 179.49);
  106.     CreateObject(3917, -220.36, 1398.63, 1115.81,   0.00, 270.00, 270.49);
  107.     CreateObject(3917, -225.04, 1398.60, 1115.81,   0.00, 270.00, 270.49);
  108.     CreateObject(3917, -210.91, 1383.21, 1115.81,   0.00, 270.00, 0.99);
  109.     CreateObject(3917, -210.89, 1379.22, 1115.81,   0.00, 270.00, 0.74);
  110.     CreateObject(3917, -195.10, 1393.38, 1115.81,   0.00, 270.00, 90.74);
  111.     CreateObject(3917, -191.08, 1393.41, 1115.81,   0.00, 270.00, 90.74);
  112.     CreateObject(3095, -199.14, 1404.94, 1131.30,   0.00, 90.00, 0.00);
  113.     CreateObject(3095, -231.59, 1391.62, 1140.58,   0.00, 0.00, 0.52);
  114.     CreateObject(3095, -231.56, 1387.20, 1136.66,   89.54, 6.00, 354.67);
  115.     CreateObject(3095, -231.68, 1400.62, 1140.59,   0.00, 0.00, 0.52);
  116.     CreateObject(3095, -240.68, 1400.52, 1140.63,   0.00, 0.00, 0.52);
  117.     CreateObject(3095, -240.61, 1391.54, 1140.59,   0.00, 0.00, 0.52);
  118.     CreateObject(3095, -240.58, 1387.09, 1136.66,   89.54, 6.00, 354.67);
  119.     CreateObject(3095, -227.55, 1391.65, 1136.66,   89.54, 6.00, 84.67);
  120.     CreateObject(3095, -227.65, 1400.67, 1136.66,   89.54, 6.00, 84.67);
  121.     CreateObject(3095, -231.96, 1404.77, 1136.66,   89.54, 6.00, 174.67);
  122.     CreateObject(3095, -240.73, 1404.67, 1136.66,   89.54, 6.00, 174.67);
  123.     CreateObject(3095, -245.02, 1400.12, 1136.66,   89.54, 6.00, 264.67);
  124.     CreateObject(3095, -244.94, 1391.11, 1136.66,   89.54, 6.00, 264.66);
  125.     CreateObject(3917, -252.97, 1398.67, 1115.81,   0.00, 270.00, 270.75);
  126.     CreateObject(3917, -248.54, 1398.71, 1115.81,   0.00, 270.00, 270.75);
  127.     CreateObject(3917, -233.67, 1412.65, 1115.81,   0.00, 270.00, 180.75);
  128.     CreateObject(3917, -233.57, 1408.30, 1115.81,   0.00, 270.00, 180.75);
  129.     CreateObject(3917, -220.02, 1393.21, 1115.81,   0.00, 270.00, 90.74);
  130.     CreateObject(3917, -238.97, 1383.16, 1115.81,   0.00, 270.00, 0.74);
  131.     CreateObject(3917, -238.94, 1379.19, 1115.81,   0.00, 270.00, 0.74);
  132.     CreateObject(3917, -223.42, 1393.18, 1115.81,   0.00, 270.00, 90.74);
  133.     CreateObject(3095, -231.22, 1358.17, 1136.66,   89.54, 6.00, 353.77);
  134.     CreateObject(3095, -240.23, 1358.21, 1136.66,   89.54, 6.00, 353.77);
  135.     CreateObject(3095, -240.25, 1362.62, 1140.68,   0.00, 0.00, 0.52);
  136.     CreateObject(3095, -231.26, 1362.71, 1140.69,   0.00, 0.00, 0.52);
  137.     CreateObject(3095, -231.36, 1371.70, 1140.68,   0.00, 0.00, 0.52);
  138.     CreateObject(3095, -240.36, 1371.61, 1140.69,   0.00, 0.00, 0.52);
  139.     CreateObject(3095, -226.88, 1362.42, 1136.66,   89.54, 6.00, 83.52);
  140.     CreateObject(3095, -226.87, 1371.40, 1136.66,   89.54, 6.00, 83.51);
  141.     CreateObject(3095, -231.05, 1375.74, 1136.66,   89.54, 6.00, 173.51);
  142.     CreateObject(3095, -240.16, 1375.84, 1136.66,   89.54, 6.00, 173.51);
  143.     CreateObject(3095, -244.34, 1371.63, 1136.66,   89.54, 6.00, 264.51);
  144.     CreateObject(3095, -244.26, 1362.63, 1136.66,   89.54, 6.00, 264.51);
  145.     CreateObject(3917, -232.65, 1379.38, 1115.81,   0.00, 270.00, 179.74);
  146.     CreateObject(3917, -232.67, 1383.69, 1115.81,   0.00, 270.00, 179.74);
  147.     CreateObject(3917, -247.97, 1370.11, 1115.81,   0.00, 270.00, 269.24);
  148.     CreateObject(3917, -252.50, 1370.18, 1115.81,   0.00, 270.00, 269.23);
  149.     CreateObject(3917, -238.32, 1353.95, 1115.81,   0.00, 270.00, 0.48);
  150.     CreateObject(3917, -238.28, 1350.23, 1115.81,   0.00, 270.00, 0.48);
  151.     CreateObject(3917, -222.97, 1364.04, 1115.81,   0.00, 270.00, 89.98);
  152.     CreateObject(3917, -218.97, 1364.01, 1115.81,   0.00, 270.00, 89.97);
  153.     CreateObject(3095, -245.31, 1404.89, 1131.30,   0.00, 90.00, 0.00);
  154.     CreateObject(9163, -168.89, 1351.02, 1136.60,   0.00, 0.00, 0.00);
  155.     CreateObject(9163, -197.00, 1329.27, 1136.60,   0.00, 0.00, 270.00);
  156.     CreateObject(9163, -235.81, 1329.25, 1136.60,   0.00, 0.00, 270.00);
  157.     CreateObject(9163, -275.02, 1329.21, 1136.60,   0.00, 0.00, 270.00);
  158.     CreateObject(9163, -271.39, 1357.41, 1136.60,   0.00, 0.00, 180.00);
  159.     CreateObject(9163, -271.37, 1396.86, 1136.60,   0.00, 0.00, 179.99);
  160.     CreateObject(9163, -271.35, 1435.19, 1136.60,   0.00, 0.00, 179.99);
  161.     CreateObject(9163, -244.80, 1432.33, 1136.60,   0.00, 0.00, 89.99);
  162.     CreateObject(9163, -206.27, 1432.36, 1136.60,   0.00, 0.00, 89.99);
  163.     CreateObject(9163, -166.67, 1432.32, 1136.60,   0.00, 0.00, 89.99);
  164.     CreateObject(9163, -169.16, 1405.46, 1136.60,   0.00, 0.00, 359.99);
  165.     CreateObject(9163, -169.07, 1389.82, 1136.60,   0.00, 0.00, 359.99);
  166.     CreateObject(9163, -271.37, 1357.30, 1144.55,   0.00, 0.00, 179.99);
  167.     CreateObject(9163, -275.02, 1329.21, 1144.58,   0.00, 0.00, 270.00);
  168.     CreateObject(9163, -235.81, 1329.25, 1144.53,   0.00, 0.00, 270.00);
  169.     CreateObject(9163, -197.00, 1329.27, 1144.55,   0.00, 0.00, 270.00);
  170.     CreateObject(9163, -168.89, 1351.02, 1144.60,   0.00, 0.00, 0.00);
  171.     CreateObject(9163, -169.07, 1389.82, 1144.60,   0.00, 0.00, 359.99);
  172.     CreateObject(9163, -169.16, 1405.46, 1144.55,   0.00, 0.00, 359.99);
  173.     CreateObject(9163, -166.67, 1432.32, 1144.58,   0.00, 0.00, 89.99);
  174.     CreateObject(9163, -206.27, 1432.36, 1144.58,   0.00, 0.00, 89.99);
  175.     CreateObject(9163, -244.80, 1432.33, 1144.55,   0.00, 0.00, 89.99);
  176.     CreateObject(9163, -271.35, 1434.81, 1144.58,   0.00, 0.00, 179.99);
  177.     CreateObject(9163, -271.33, 1397.00, 1144.53,   0.00, 0.00, 179.99);
  178.     CreateObject(3915, -219.76, 1432.81, 1132.33,   0.00, 0.00, 89.98);
  179.     CreateObject(3915, -250.99, 1433.00, 1132.33,   0.00, 0.00, 89.98);
  180.     CreateObject(3915, -270.43, 1378.81, 1132.33,   0.00, 0.00, 179.98);
  181.     CreateObject(3915, -270.80, 1380.86, 1132.28,   0.00, 0.00, 179.97);
  182.     CreateObject(3917, -241.97, 1379.26, 1125.60,   0.00, 0.00, 0.00);
  183.     CreateObject(3917, -242.42, 1366.28, 1125.60,   0.00, 0.00, 0.00);
  184.     CreateObject(3917, -252.79, 1365.78, 1125.60,   0.00, 0.00, 0.00);
  185.     CreateObject(3917, -241.34, 1353.32, 1125.60,   0.00, 0.00, 0.00);
  186.     CreateObject(3917, -241.79, 1340.29, 1125.60,   0.00, 0.00, 0.00);
  187.     CreateObject(3917, -223.99, 1367.25, 1125.60,   0.00, 0.00, 0.00);
  188.     CreateObject(3917, -231.74, 1367.62, 1125.88,   0.00, 0.00, 0.00);
  189.     CreateObject(3915, -241.45, 1423.45, 1116.10,   0.00, 90.00, 270.08);
  190.     CreateObject(3915, -200.81, 1423.49, 1116.10,   0.00, 90.00, 270.07);
  191.     CreateObject(3915, -165.13, 1423.29, 1116.10,   0.00, 90.00, 270.07);
  192.     CreateObject(3915, -178.04, 1402.66, 1116.10,   0.00, 90.00, 180.07);
  193.     CreateObject(3915, -177.92, 1360.46, 1116.10,   0.00, 90.00, 180.07);
  194.     CreateObject(3915, -199.14, 1338.15, 1116.10,   0.00, 90.00, 90.07);
  195.     CreateObject(3915, -241.66, 1338.36, 1116.10,   0.00, 90.00, 90.06);
  196.     CreateObject(3915, -262.38, 1359.60, 1116.10,   0.00, 90.00, 0.06);
  197.     CreateObject(3915, -262.44, 1401.90, 1116.10,   0.00, 90.00, 0.06);
  198.     CreateObject(3915, -262.48, 1443.27, 1116.10,   0.00, 90.00, 0.06);
  199.     CreateObject(3915, -178.04, 1318.20, 1116.10,   0.00, 90.00, 180.06);
  200.     CreateObject(3095, -244.20, 1357.31, 1131.30,   0.00, 90.00, 0.00);
  201.     CreateObject(1224, -244.04, 1405.98, 1132.74,   0.00, 0.00, 0.00);
  202.     CreateObject(1224, -199.85, 1405.97, 1132.74,   0.00, 0.00, 0.00);
  203.     CreateObject(1224, -242.94, 1356.84, 1132.74,   0.00, 0.00, 0.00);
  204.     CreateObject(1224, -199.95, 1356.23, 1132.74,   0.00, 0.00, 0.00);
  205. //_______________________________The CT & T neons + angels______________________
  206.     CreateObject(18647, -258.73, 1419.59, 1132.17,   0.00, 0.00, 45.00);
  207.     CreateObject(18647, -260.15, 1421.00, 1132.17,   0.00, 0.00, 45.00);
  208.     CreateObject(18647, -260.21, 1422.38, 1132.17,   0.00, 0.00, 135.00);
  209.     CreateObject(18647, -261.57, 1421.02, 1132.17,   0.00, 0.00, 135.00);
  210.     CreateObject(18648, -180.98, 1343.22, 1132.14,   0.00, 0.00, 142.00);
  211.     CreateObject(18648, -181.68, 1340.75, 1132.14,   0.00, 0.00, 45.00);
  212.     CreateObject(18648, -180.96, 1340.07, 1132.14,   0.00, 0.00, 142.00);
  213.     CreateObject(18648, -179.58, 1341.84, 1132.14,   0.00, 0.00, 142.00);
  214.     CreateObject(18648, -179.68, 1343.31, 1132.14,   0.00, 0.00, 45.00);
  215.     CreateObject(3462, -179.12, 1422.37, 1133.63,   0.00, 0.00, 47.00);
  216.     CreateObject(3462, -261.00, 1339.45, 1133.63,   0.00, 0.00, 229.00);
  217. //______________________________________________________________________________
  218.     print(" ______________________ ");
  219.     print("| FY_Snow event loaded |");
  220.     print("|      by DiGiTaL_AnGeL|");
  221.     print("|______________________|");
  222.     return 1;
  223. }
  224.  
  225. public OnFilterScriptExit()
  226. {
  227.     print(" ________________________");
  228.     print("| FY_Snow event unloaded |");
  229.     print("|       by DiGiTaL_AnGeL |");
  230.     print("|________________________|");
  231.     return 1;
  232. }
  233. //_________________________________OnDialogResponse_____________________________
  234. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  235. {
  236.     if(dialogid == TSelect)
  237.     {
  238.         if(response)
  239.         {
  240.             if(listitem == 0)
  241.             {
  242.                 SetPlayerPos(playerid, -181.5529, 1342.0728, 1133.0503);
  243.                 SetPlayerSkin(playerid, 285);
  244.                 SCM(playerid, ALBASTRU, "You have chosen the CT team! Your objective is to kill the terrorists!");
  245.                 ResetPlayerWeapons(playerid);
  246.                 GivePlayerWeapon(playerid, 4, 1);//Knife
  247.                 GivePlayerWeapon(playerid, 16, 1);//Grenade
  248.                 GivePlayerWeapon(playerid, 23, 200);//SD Pistol
  249.                 GivePlayerWeapon(playerid, 29, 500);//MP5
  250.                 GivePlayerWeapon(playerid, 31, 500);//M4
  251.                 GivePlayerWeapon(playerid, 34, 100);//Sniper
  252.                 TogglePlayerControllable(playerid, 0);
  253.                 ct = 1;
  254.             }
  255.             if(listitem == 1)
  256.             {
  257.                 SetPlayerPos(playerid, -259.5252, 1420.4543, 1133.0581);
  258.                 SetPlayerSkin(playerid, 122);
  259.                 SCM(playerid, ROSU, "You have chosen the Terrorists team! You objective is to kill all the CTs. Exterminate!");
  260.                 ResetPlayerWeapons(playerid);
  261.                 GivePlayerWeapon(playerid, 4, 1);//Knife
  262.                 GivePlayerWeapon(playerid, 16, 1);//Grenade
  263.                 GivePlayerWeapon(playerid, 24, 500);//Deagle
  264.                 GivePlayerWeapon(playerid, 28, 500);//Uzi
  265.                 GivePlayerWeapon(playerid, 30, 500);//AK 47
  266.                 GivePlayerWeapon(playerid, 34, 100);//Sniper
  267.                 GivePlayerWeapon(playerid, 39, 1);//C4
  268.                 TogglePlayerControllable(playerid, 0);
  269.                 terro = 1;
  270.             }
  271.         }
  272.         return 1;
  273.     }
  274.     return 0;
  275. }
  276.  
  277. public OnPlayerDeath(playerid, killerid, reason)
  278. {
  279.     if (terro == 1 || ct == 1)
  280.     {
  281.         ResetPlayerWeapons(playerid);
  282.         SCM(playerid, ROSU, "You have died in battle! Thank you for playing!");
  283.         return 1;
  284.     }
  285.     return 1;
  286. }
  287.  
  288. public EC3()
  289. {
  290.     for(new i = 0; i <= MAX_PLAYERS; i++)
  291.     {
  292.         if(IsPlayerConnected(i))
  293.         {
  294.             GameTextForPlayer(i,"~r~Event Countdown: ~n~~n~~r~3",1000,4);
  295.             new Float:X, Float:Y, Float:Z;
  296.             GetPlayerPos(i, X,Y,Z);
  297.             PlayerPlaySound(i, 1056, X, Y, Z);
  298.         }
  299.     }
  300.     return 1;
  301. }
  302.  
  303. public EC2()
  304. {
  305.     for(new i = 0; i<= MAX_PLAYERS; i++)
  306.     {
  307.         if(IsPlayerConnected(i))
  308.         {
  309.             GameTextForPlayer(i, "~r~Event Countdown: ~n~~n~~r~2", 1000, 4);
  310.             new Float:x, Float:y, Float:z;
  311.             GetPlayerPos(i, x, y, z);
  312.             PlayerPlaySound(i, 1056, x, y, z);
  313.         }
  314.     }
  315.     return 1;
  316. }
  317.  
  318. public EC1()
  319. {
  320.     for(new i = 0; i<= MAX_PLAYERS; i++)
  321.     {
  322.         if(IsPlayerConnected(i))
  323.         {
  324.             GameTextForPlayer(i, "~r~Event Countdown: ~n~~n~~r~1", 1000, 4);
  325.             new Float:x, Float:y, Float:z;
  326.             GetPlayerPos(i, x, y, z);
  327.             PlayerPlaySound(i, 1056, x, y, z);
  328.         }
  329.     }
  330.     return 1;
  331. }
  332.  
  333. public ES()
  334. {
  335.     for(new i = 0; i<= MAX_PLAYERS; i++)
  336.     {
  337.         if(IsPlayerConnected(i))
  338.         {
  339.             GameTextForPlayer(i, "~r~Event Countdown: ~n~~n~~u~~r~Start!~u~", 1000, 4);
  340.             new Float:x, Float:y, Float:z;
  341.             GetPlayerPos(i, x, y, z);
  342.             PlayerPlaySound(i, 1056, x, y, z);
  343.             TogglePlayerControllable(i, 1);
  344.         }
  345.     }
  346.     return 1;
  347. }
  348.  
  349. //__________________________________<+>COMMANDS<+>______________________________
  350. YCMD:fsevent(playerid, params[], help)
  351. {
  352.     #pragma unused params, help
  353.     if(IsPlayerAdmin(playerid))
  354.     {
  355.         if(fsevent == 0)
  356.         {
  357.             fsevent =1;
  358.             SCM(playerid, VERDE, "You have succesfully activated the fy_snow event!");
  359.             SCMTA(PORTOCALIU, "The Fy_Snow event has been activated! Type /joinfsevent to join!");
  360.         }
  361.         else if(fsevent == 0)
  362.         {
  363.             SCM(playerid, ROSU, "The Fy Snow event is already activated!");
  364.         }
  365.     }
  366.     else
  367.     {
  368.         SCM(playerid, ROSU, "You don't have the permission to do that!");
  369.     }
  370.     return 1;
  371. }
  372. YCMD:joinfsevent(playerid, params[], help)
  373. {
  374.     #pragma unused params, help
  375.     if(fsevent == 1)
  376.     {
  377.         ShowPlayerDialog(playerid, TSelect, DIALOG_STYLE_LIST, "Choose a team!", "{0000FF}Counter Terrorists\n{FF0000}Terrorists", "OK", "Abort");
  378.     }
  379.     else if(fsevent == 0)
  380.     {
  381.         SCM(playerid, MOV, "The Fy_Snow event is not activated!");
  382.     }
  383.     return 1;
  384. }
  385. YCMD:startevent(playerid, params[], help)
  386. {
  387.     #pragma unused params, help
  388.     if(IsPlayerAdmin(playerid))
  389.     {
  390.         if(fsevent == 0)
  391.         {
  392.             SCM(playerid, GALBEN, "The Fy Snow event is not activated!");
  393.         }
  394.         else if(fsevent == 1)
  395.         {
  396.             SCM(playerid, MARO, "The event will start in 5 seconds!");
  397.             fsevent = 0;
  398.             SetTimer("EC3", 1000, 0);
  399.             SetTimer("EC2", 2000, 0);
  400.             SetTimer("EC1", 3000, 0);
  401.             SetTimer("ES", 3500, 0);
  402.         }
  403.     }
  404.     else
  405.     {
  406.         SCM(playerid, ROSU, "You don't have the permission to do that!");
  407.     }
  408.     return 1;
  409. }
  410. YCMD:snowoff(playerid, params[], help)
  411. {
  412.     #pragma unused params, help
  413.     if(IsPlayerAdmin(playerid))
  414.     {
  415.         if(destroyedsnow == 1)
  416.         {
  417.             SCM(playerid, GRI, "The snow is already disabled!");
  418.         }
  419.         else
  420.         {
  421.             DestroyObject(snow[1]);
  422.             DestroyObject(snow[2]);
  423.             SCM(playerid, VERDE, "You have disabled the snow! To activate it type /snow!");
  424.             destroyedsnow = 1;
  425.         }
  426.     }
  427.     else
  428.     {
  429.         SCM(playerid, ROSU, "You don't have the permission to do that!");
  430.     }
  431.     return 1;
  432. }
  433. YCMD:snow(playerid, params[], help)
  434. {
  435.     #pragma unused params, help
  436.     if(IsPlayerAdmin(playerid))
  437.     {
  438.         if(destroyedsnow == 0)
  439.         {
  440.             SCM(playerid, MOV, "The snow it's already enabled!");
  441.         }
  442.         else
  443.         {
  444.             SCM(playerid, GRI, "The snow is enabled again!");
  445.             snow[1] = CreateObject(18864, -164.14, 1418.76, 1119.20,   47.00, -91.00, 69.00);
  446.             snow[2] = CreateObject(18864, -148.04, 1411.10, 1119.20,   47.00, -91.00, 69.00);
  447.             destroyedsnow = 0;
  448.         }
  449.     }
  450.     else
  451.     {
  452.         SCM(playerid, ROSU, "You don't have the permission to do that!");
  453.     }
  454.     return 1;
  455. }
  456. YCMD:leavefs(playerid, params[], help)
  457. {
  458.     #pragma unused params, help
  459.     if(ct == 1 || terro == 1)
  460.     {
  461.         SpawnPlayer(playerid);
  462.         SCM(playerid, MOV, "You have left the event and lost $500!");
  463.         ResetPlayerWeapons(playerid);
  464.         GivePlayerMoney(playerid, -500);
  465.         TogglePlayerControllable(playerid, 1);
  466.     }
  467.     else
  468.     {
  469.         SCM(playerid, ROSU, "You are not at the event!");
  470.     }
  471.     return 1;
  472. }
  473. YCMD:fshelp(playerid, params[], help)
  474. {
  475.     #pragma unused params, help
  476.     new info[300];
  477.     if(IsPlayerAdmin(playerid))
  478.     {
  479.         strcat(info, "{FF0000}To enable/disable the event ~> /fsevent\n", sizeof(info));
  480.         strcat(info, "{00FF00}To start the event ~> /startevent\n", sizeof(info));
  481.         strcat(info, "{0000FF}To disable the snow ~> /snowoff\n", sizeof(info));
  482.         strcat(info, "{FFFF00}To enable the snow ~> /snpw\n", sizeof(info));
  483.         strcat(info, "{FF00FF}To join the event ~> /joinfsevent\n", sizeof(info));
  484.         strcat(info, "{00FFFF}To leave the event ~> /leavefs\n", sizeof(info));
  485.         ShowPlayerDialog(playerid, Help, DIALOG_STYLE_MSGBOX, "Fy Snow help", info, "OK", "");
  486.     }
  487.     return 1;
  488. }
  489. #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement