noahfallon

NoahF's Random/Useful Teleports v1.2

Sep 18th, 2012
300
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 8.79 KB | None | 0 0
  1. #include <a_samp> //Includes.
  2. #include <zcmd> //Includes.
  3. //
  4. #define FILTERSCRIPT //Defining this as a FilterScript..
  5. #define blue 0x375FFFFF //Defining the color blue.
  6. #define red 0xCF2E2EB6 //Defining the color red.
  7. #define green 0x00FF00B6 //Defining the color green.
  8. #define orange 0xFF8040B6
  9. #define lightblue 0x00FFFFB6
  10. #define darklightblue 0x0080FFB6
  11. #define seagreen 0x008080C5
  12. #define EMBED_RED {CF2E2E} //Defining the embed.
  13. #define EMBED_BLUE {375FFF} //Defining the embed.
  14. #define EMBED_GREEN {00FF00} //Defining the embed.
  15. #define EMBED_ORANGE {FF8040}
  16. #define EMBED_LIGHTBLUE {00FFFF}
  17. #define EMBED_DARKLIGHTBLUE {0080FF}
  18. #define EMBED_SEAGREEN {008080}
  19. #define SCMTA SendClientMessageToAll //Defining SCMTA as SendClientMessageToAll so I don't have to type it out each time.
  20. //
  21. #define DIALOG_TPORT 17328 //Defining the dialog.
  22. //Declaring the variables..
  23. new string[128];
  24. new string1[128];
  25. new string2[128];
  26. new string3[128];
  27. new string4[128];
  28. new string5[128];
  29. new string6[128];
  30. new string7[128];
  31. new string8[128];
  32. new string9[128];
  33. new string10[128];
  34. new string11[128];
  35. new string12[128];
  36. new string13[128];
  37. new pName[24];
  38. new pName1[24];
  39. new pName2[24];
  40. new pName3[24];
  41. new pName4[24];
  42. new pName5[24];
  43. new pName6[24];
  44. new pName7[24];
  45. new pName8[24];
  46. new pName9[24];
  47. new pName10[24];
  48. new pName11[24];
  49. new pName12[24];
  50. new pName13[24];
  51. new pName14[24];
  52.  
  53. public OnFilterScriptInit()
  54. {
  55.     print("*************************************************");  // Prints a message on Samp-Server.exe saying the filterscript has loaded.
  56.     print("------------------------EPIC-------------------------------");
  57.     print("NoahF's Random/Useful teleports has loaded!");
  58.     print("*************************************************");
  59.     print("------------------------EPIC-------------------------------");
  60.     return 1;
  61. }
  62. public OnFilterScriptExit()
  63. {
  64.     print("*************************************************");  // Prints a message on Samp-Server.exe saying the filterscript has unloaded.
  65.     print("------------------------EPIC-------------------------------");
  66.     print("NoahF's Random/Useful teleports has unloaded!");
  67.     print("*************************************************");
  68.     print("------------------------EPIC-------------------------------");
  69.     return 1;
  70. }
  71. CMD:teleports(playerid, params[])
  72. {
  73.     ShowPlayerDialog(playerid, 17328, DIALOG_STYLE_LIST, "Teleports", "{CF2E2E}Los Santos Hospital\n{375FFF}Los Santos Airport\n{00FF00}Los Santos Police Department\n{FF8040}Las Venturas Bike Jump\n{375FFF}Las Venturas Pyramid\n{CF2E2E}Las Venturas Sniping-Spot\n{00FF00}Las Venturas Crane\n{375FFF}Las Venturas Police Department\n{CF2E2E}Las Venturas Airport\n{375FFF}Exact Middle of San Andreas\n{00FF00}Soda Can\n{0080FF}Red County Docks\n{CF2E2E}Random Place 1\n{008080}Skydive", "Select", "Close");
  74.     return 1;
  75. }
  76. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  77. {
  78.     if(dialogid == DIALOG_TPORT)
  79.     {
  80.         if(response) // If the player clicked a song
  81.         {
  82.             if(listitem == 1)
  83.             {
  84.                 SetPlayerPos(playerid,2025.133056,-1419.697000,16.992187);
  85.                 SendClientMessage(playerid, blue, "You have teleported to the LS Hospital.");
  86.                 GetPlayerName(playerid, pName, 24);
  87.                 format(string, 128, "%s has teleported to the {00FF00}Los Santos Hospital.", pName);
  88.                 SCMTA(blue, string);
  89.             }
  90.             if(listitem == 2)
  91.             {
  92.                 SetPlayerPos(playerid,1642.62,-2333.79,13.55);
  93.                 SendClientMessage(playerid, blue, "You have teleported to Los Santos Airport.");
  94.                 GetPlayerName(playerid, pName2, 24);
  95.                 format(string1, 128, "%s has teleported to the {00FF00}Los Santos Airport.", pName1);
  96.                 SCMTA(blue, string1);
  97.             }
  98.             if(listitem == 3)
  99.             {
  100.                 SetPlayerPos(playerid,1549.387084,-1668.78100,13.564489);
  101.                 SendClientMessage(playerid,blue, "You have teleported to Los Santos Police Department.");
  102.                 GetPlayerName(playerid, pName3, 24);
  103.                 format(string2, 128, "%s has teleported to the {00FF00}Los Santos Police Department.", pName2);
  104.                 SCMTA(blue, string2);
  105.             }
  106.             if(listitem == 4)
  107.             {
  108.                 SetPlayerPos(playerid,-664.36,2305.05,135.74);
  109.                 SendClientMessage(playerid,blue, "You have teleported to the Las Venturas Bike Jump.");
  110.                 GetPlayerName(playerid, pName4, 24);
  111.                 format(string3, 128, "%s has teleported to the {00FF00}Las Venturas Bike Jump.", pName3);
  112.                 SCMTA(blue, string3);
  113.             }
  114.             if(listitem == 5)
  115.             {
  116.                 SetPlayerPos(playerid,2323.72,1283.32,97.54);
  117.                 SendClientMessage(playerid,blue, "You have teleported to the Las Venturas Pyramid.");
  118.                 GetPlayerName(playerid, pName5, 24);
  119.                 format(string4, 128, "%s has teleported to the {FF00FF}Las Venturas Pyramid.", pName4);
  120.                 SCMTA(blue, string4);
  121.             }
  122.             if(listitem == 6)
  123.             {
  124.                 SetPlayerPos(playerid,2344.15,1282.82,68.33);
  125.                 SendClientMessage(playerid,blue, "You have teleported to the Las Venturas Sniping Spot.");
  126.                 GetPlayerName(playerid, pName6, 24);
  127.                 format(string5, 128, "%s has teleported to the {FF00FF}Las Venturas Sniping Spot.", pName6);
  128.                 SCMTA(blue, string5);
  129.             }
  130.             if(listitem == 7)
  131.             {
  132.                 SetPlayerPos(playerid,2398.91,1865.60,76.55);
  133.                 SendClientMessage(playerid,blue, "You have teleported to the Las Venturas Crane.");
  134.                 GetPlayerName(playerid, pName7, 24);
  135.                 format(string6, 128, "%s has teleported to the {FF00FF}Las Venturas Crane.", pName7);
  136.                 SCMTA(blue, string6);
  137.             }
  138.             if(listitem == 8)
  139.             {
  140.                 SetPlayerPos(playerid,2284.698730,2427.671875,10.820312);
  141.                 SendClientMessage(playerid,blue, "You have teleported to Las Venturas Police Department.");
  142.                 GetPlayerName(playerid, pName8, 24);
  143.                 format(string7, 128, "%s has teleported to the {FF00FF}Las Venturas Police Department.", pName8);
  144.                 SCMTA(blue, string7);
  145.             }
  146.             if(listitem == 9)
  147.             {
  148.                 SetPlayerPos(playerid,1684.706420,1432.456665,10.770483);
  149.                 SendClientMessage(playerid,blue, "You have teleported to Las Venturas Airport.");
  150.                 GetPlayerName(playerid, pName9, 24);
  151.                 format(string8, 128, "%s has teleported to the {FF00FF}Las Venturas Airport.", pName9);
  152.                 SCMTA(blue, string8);
  153.             }
  154.             if(listitem == 10)
  155.             {
  156.                 SetPlayerPos(playerid,0.0,0.0,3.0);
  157.                 SendClientMessage(playerid,blue, "You have teleported to the exact middle of San Andreas.");
  158.                 GetPlayerName(playerid, pName10, 24);
  159.                 format(string9, 128, "%s has teleported to the {FF00FF}middle of San Andreas.", pName10);
  160.                 SCMTA(blue, string9);
  161.             }
  162.             if(listitem == 11)
  163.             {
  164.                 SetPlayerPos(playerid,1309.738403,255.183334,36.615425);
  165.                 SendClientMessage(playerid,blue, "You have teleported to the top of a soda can in Montgomery.");
  166.                 GetPlayerName(playerid, pName11, 24);
  167.                 format(string10, 128, "%s has teleported to the {FF00FF}top of a soda can in Montgomery.", pName11);
  168.                 SCMTA(blue, string10);
  169.             }
  170.             if(listitem == 13)
  171.             {
  172.                 SetPlayerPos(playerid,2288.134765,608.165283,10.820312);
  173.                 SendClientMessage(playerid,blue, "You have teleported to the Red County Docks.");
  174.                 GetPlayerName(playerid, pName12, 24);
  175.                 format(string11, 128, "%s has teleported to the {FF00FF}Red County Docks.", pName12);
  176.                 SCMTA(blue, string11);
  177.             }
  178.             if(listitem == 14)
  179.             {
  180.                 SetPlayerPos(playerid,1324.232244,832.221313,15.532247);
  181.                 SendClientMessage(playerid,blue, "You have teleported to NoahF's Random Place.");
  182.                 GetPlayerName(playerid, pName13, 24);
  183.                 format(string12, 128, "%s has teleported to {FF00FF}NoahF's Random Place.", pName13);
  184.                 SCMTA(blue, string12);
  185.             }
  186.             if(listitem == 15)
  187.             {
  188.                 SetPlayerPos(playerid,2308.833007,1087.774902,1307.941772);
  189.                 SendClientMessage(playerid,blue, "You have teleported to Skydive Spot 1.");
  190.                 GetPlayerName(playerid, pName14, 24);
  191.                 format(string13, 128, "%s has teleported to the {FF00FF}Skydive Spot 1.", pName14);
  192.                 SCMTA(blue, string13);
  193.             }
  194.         }
  195.     }
  196. }
  197.  
  198.  
  199.  
  200. /*
  201. -----------------------------------------CREDITS----------------------------------------
  202. NoahF's Random/Useful Teleports FilterScript scripted/created by Noah Fallon (NoahF) on 8/3/12.
  203. Please do not remove these credits.
  204. Changing things are allowed but when you do please post the newly modified code in a reply to my SA-MP Forums topic on this FS.
  205. Thanks for using ;)
  206. Also, don't be afraid to put some constructive criticism in a reply to the topic! This is my first FS and I would like to know how I can improve on future scripts. :)
  207.  
  208. UPDATE 1.1 8/31/12
  209. CHANGELOG v1.1:
  210. Completely rescripted everything to put it all in a clickable dialog.
  211.  
  212. UPDATE 1.2 9/17/12
  213. CHANGELOG V1.2:
  214. Added a variety of colors to the text to make the dialog look nicer.
  215. Added in when a player teleports to a spot, it says "So&So has teleported to Blablah"
  216. Added in embedded colors.
  217. -----------------------------------------END OF CREDITS---------------------------------
  218. */
Advertisement
Add Comment
Please, Sign In to add comment