Guest User

[FS] Toy Script - Travis The Tiger

a guest
Aug 7th, 2012
1,069
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 8.66 KB | None | 0 0
  1. /*
  2. --------------------------------------------------------------------------------
  3.         Filterscript made by, Travis The Tiger.
  4. --------------------------------------------------------------------------------
  5. */
  6.  
  7.  
  8.  
  9.  
  10.  
  11. #include <a_samp>
  12. #include <zcmd>
  13.  
  14. #define         COLOR_WHITE         0xFFFFFFAA
  15.  
  16. public OnFilterScriptInit()
  17. {
  18.     print("\n--------------------------------------");
  19.     print(" Travis The Tiger");
  20.     print("--------------------------------------\n");
  21.     return 1;
  22. }
  23.  
  24. public OnFilterScriptExit()
  25. {
  26.     return 1;
  27. }
  28.  
  29.  
  30.  
  31. //-----------------------------------------------Command---------------------------------------------------------------------------------
  32.  
  33. command(toys, playerid, prams[])
  34. {
  35.     ShowPlayerDialog(playerid, 9000, DIALOG_STYLE_LIST, "Objects", "Bandanna's (1)\nGlasses (2)\nLasers (3)\nMiscallaneous (4)\nRemove\nAdjust", "Select", "Cancel");
  36.     return 1;
  37. }
  38.  
  39. //---------------------------------------------Dialog Menu's-------------------------------------------------------------------------------
  40.  
  41. public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
  42. {
  43.     if(response)
  44.     {
  45.         switch(dialogid)
  46.         {
  47.             case 9000:  // Menu For Toys
  48.             {
  49.                 switch(listitem)
  50.                 {
  51.                     case 0:
  52.                     {
  53.                         ShowPlayerDialog(playerid, 9001, DIALOG_STYLE_LIST, "Bandanas", "Black\nWhite\nGreen", "Select", "Cancel");
  54.                         return 1;
  55.                     }
  56.                     case 1:
  57.                     {
  58.                         ShowPlayerDialog(playerid, 9002, DIALOG_STYLE_LIST, "Glasses", "Red Aviator's\nBlue Aviator's\nPurple Aviator's\nGreen Aviator's\nBlack SWAT\nBlue SWAT\nRed SWAT", "Select", "Cancel");
  59.                         return 1;
  60.                     }
  61.                     case 2:
  62.                     {
  63.                         ShowPlayerDialog(playerid, 9003, DIALOG_STYLE_LIST, "Lasers", "Laser 1\nLaser 2\nLaser 3\nLaser 4\nLaser 5", "Select", "Cancel");
  64.                         return 1;
  65.                     }
  66.                     case 3:
  67.                     {
  68.                         ShowPlayerDialog(playerid, 9004, DIALOG_STYLE_LIST, "Miscallaneous", "Gas Mask\nSWAT Armour\nPolice Shield\nGuitar", "Select", "Cancel");
  69.                         return 1;
  70.                     }
  71.                     case 4:
  72.                     {
  73.                         ShowPlayerDialog(playerid, 9005, DIALOG_STYLE_LIST, "Remove", "1\n2\n3\n4", "Select", "Cancel");
  74.                         return 1;
  75.                     }
  76.                     case 5:
  77.                     {
  78.                         ShowPlayerDialog(playerid, 9006, DIALOG_STYLE_LIST, "Adjust", "1\n2\n3\n4", "Select", "Cancel");
  79.                         return 1;
  80.                     }
  81.                 }
  82.             }
  83.             case 9001:  // Bandanas
  84.             {
  85.                 switch(listitem)
  86.                 {
  87.                     case 0:  // Black Bandana
  88.                     {
  89.                         RemovePlayerAttachedObject(playerid, 1);
  90.                         SetPlayerAttachedObject(playerid, 1, 18912, 2, 8, 2.5, 0, 90, 180, 90, 1, 1, 1);
  91.                         EditAttachedObject(playerid, 1);
  92.                         return 1;
  93.                     }
  94.                     case 1:  // White Bandana
  95.                     {
  96.                         RemovePlayerAttachedObject(playerid, 1);
  97.                         SetPlayerAttachedObject(playerid, 1, 18919, 2, 8, 2.5, 0, 90, 180, 90, 1, 1, 1);
  98.                         EditAttachedObject(playerid, 1);
  99.                         return 1;
  100.                     }
  101.                     case 2:  // Green Bandana
  102.                     {
  103.                         RemovePlayerAttachedObject(playerid, 1);
  104.                         SetPlayerAttachedObject(playerid, 1, 18913, 2, 8, 2.5, 0, 90, 180, 90, 1, 1, 1);
  105.                         EditAttachedObject(playerid, 1);
  106.                         return 1;
  107.                     }
  108.                 }
  109.             }
  110.             case 9002: // Glasses
  111.             {
  112.                 switch(listitem)
  113.                 {
  114.                     case 0:  // Red Aviators
  115.                     {
  116.                         RemovePlayerAttachedObject(playerid, 2);
  117.                         SetPlayerAttachedObject(playerid, 2, 19026, 2, 8, 4, 0, 90, 90, 0, 1, 1, 1);
  118.                         EditAttachedObject(playerid, 2);
  119.                         return 1;
  120.                     }
  121.                     case 1: // Blue Aviators
  122.                     {
  123.                         RemovePlayerAttachedObject(playerid, 2);
  124.                         SetPlayerAttachedObject(playerid, 2, 19023, 2, 8, 4, 0, 90, 90, 0, 1, 1, 1);
  125.                         EditAttachedObject(playerid, 2);
  126.                         return 1;
  127.                     }
  128.                     case 2: //  Purple Aviators
  129.                     {
  130.                         RemovePlayerAttachedObject(playerid, 2);
  131.                         SetPlayerAttachedObject(playerid, 2, 19024, 2, 8, 4, 0, 90, 90, 0, 1, 1, 1);
  132.                         EditAttachedObject(playerid, 2);
  133.                         return 1;
  134.                     }
  135.                     case 3: // Green Aviators
  136.                     {
  137.                         RemovePlayerAttachedObject(playerid, 2);
  138.                         SetPlayerAttachedObject(playerid, 2, 19028, 2, 8, 4, 0, 90, 90, 0, 1, 1, 1);
  139.                         EditAttachedObject(playerid, 2);
  140.                         return 1;
  141.                     }
  142.                     case 4: //Black SWAT Glasses
  143.                     {
  144.                         RemovePlayerAttachedObject(playerid, 2);
  145.                         SetPlayerAttachedObject(playerid, 2, 19138, 2, 8, 4, 0, 90, 90, 0, 1, 1, 1);
  146.                         EditAttachedObject(playerid, 2);
  147.                         return 1;
  148.                     }
  149.                     case 5: //Blue SWAT Glasses
  150.                     {
  151.                         RemovePlayerAttachedObject(playerid, 2);
  152.                         SetPlayerAttachedObject(playerid, 2, 19139, 2, 0, 0, 0, 0, 0, 0, 1, 1, 1);
  153.                         EditAttachedObject(playerid, 2);
  154.                         return 1;
  155.                     }
  156.                     case 6: //Red SWAT Glasses
  157.                     {
  158.                         RemovePlayerAttachedObject(playerid, 2);
  159.                         SetPlayerAttachedObject(playerid, 2, 19340, 2, 8, 4, 0, 90, 90, 0, 1, 1, 1);
  160.                         EditAttachedObject(playerid, 2);
  161.                         return 1;
  162.                     }
  163.                 }
  164.             }
  165.             case 9003:
  166.             {
  167.                 switch(listitem)
  168.                 {
  169.                     case 0: // Unknown Laser
  170.                     {
  171.                         RemovePlayerAttachedObject(playerid, 3);
  172.                         SetPlayerAttachedObject(playerid, 3, 19080, 6, 0, 0, 0, 0, 0, 0, 1, 1, 1);
  173.                         EditAttachedObject(playerid, 3);
  174.                         return 1;
  175.                     }
  176.                     case 1: // Unknown Laser
  177.                     {
  178.                         RemovePlayerAttachedObject(playerid, 3);
  179.                         SetPlayerAttachedObject(playerid, 3, 19081, 6, 0, 0, 0, 0, 0, 0, 1, 1, 1);
  180.                         EditAttachedObject(playerid, 3);
  181.                         return 1;
  182.                     }
  183.                     case 2: // Unknown Laser
  184.                     {
  185.                         RemovePlayerAttachedObject(playerid, 3);
  186.                         SetPlayerAttachedObject(playerid, 3, 19082, 6, 0, 0, 0, 0, 0, 0, 1, 1, 1);
  187.                         EditAttachedObject(playerid, 3);
  188.                         return 1;
  189.                     }
  190.                     case 3:  // Unknown Laser
  191.                     {
  192.                         RemovePlayerAttachedObject(playerid, 3);
  193.                         SetPlayerAttachedObject(playerid, 3, 19083, 6, 0, 0, 0, 0, 0, 0, 1, 1, 1);
  194.                         EditAttachedObject(playerid, 3);
  195.                         return 1;
  196.                     }
  197.                     case 4: // Unknown Laser
  198.                     {
  199.                         RemovePlayerAttachedObject(playerid, 3);
  200.                         SetPlayerAttachedObject(playerid, 3, 19084, 6, 0, 0, 0, 0, 0, 0, 1, 1, 1);
  201.                         EditAttachedObject(playerid, 3);
  202.                         return 1;
  203.                     }
  204.                 }
  205.             }
  206.             case 9004:
  207.             {
  208.                 switch(listitem)
  209.                 {
  210.                     case 0: // Gas Mask
  211.                     {
  212.                         RemovePlayerAttachedObject(playerid, 1);
  213.                         SetPlayerAttachedObject(playerid, 1, 19472, 2, 0, 0, 0, 0, 0, 0, 1, 1, 1);
  214.                         EditAttachedObject(playerid, 1);
  215.                         return 1;
  216.                     }
  217.                     case 1: // SWAT Armour
  218.                     {
  219.                         RemovePlayerAttachedObject(playerid, 4);
  220.                         SetPlayerAttachedObject(playerid, 4, 19142, 1, 12, 6, 0, 0, 0, 0, 1, 1, 1);
  221.                         EditAttachedObject(playerid, 4);
  222.                         return 1;
  223.                     }
  224.                     case 2: // Police Shield
  225.                     {
  226.                         RemovePlayerAttachedObject(playerid, 4);
  227.                         SetPlayerAttachedObject(playerid, 4, 18637, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1);
  228.                         EditAttachedObject(playerid, 4);
  229.                         return 1;
  230.                     }
  231.                     case 3: // Guitar
  232.                     {
  233.                         RemovePlayerAttachedObject(playerid, 4);
  234.                         SetPlayerAttachedObject(playerid, 4, 19317, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1);
  235.                         EditAttachedObject(playerid, 4);
  236.                         return 1;
  237.                     }
  238.                 }
  239.             }
  240.             case 1005:
  241.             {
  242.                 switch(listitem)
  243.                 {
  244.                     case 0: // Remove The Toy From Slot 1
  245.                     {
  246.                         RemovePlayerAttachedObject(playerid, 1);
  247.                         return 1;
  248.                     }
  249.                     case 1: // Remove The Toy From Slot 2
  250.                     {
  251.                         RemovePlayerAttachedObject(playerid, 2);
  252.                         return 1;
  253.                     }
  254.                     case 2: // Remove The Toy From Slot 3
  255.                     {
  256.                         RemovePlayerAttachedObject(playerid, 3);
  257.                         return 1;
  258.                     }
  259.                     case 3: // Remove The Toy From Slot 4
  260.                     {
  261.                         RemovePlayerAttachedObject(playerid, 4);
  262.                         return 1;
  263.                     }
  264.                 }
  265.             }
  266.             case 9006:
  267.             {
  268.                 switch(listitem)
  269.                 {
  270.                     case 0: // Adjust Toy Slot 1
  271.                     {
  272.                         EditAttachedObject(playerid, 1);
  273.                         return 1;
  274.                     }
  275.                     case 1: // Adjust Toy Slot 2
  276.                     {
  277.                         EditAttachedObject(playerid, 2);
  278.                         return 1;
  279.                     }
  280.                     case 2: // Adjust Toy Slot 3
  281.                     {
  282.                         EditAttachedObject(playerid, 3);
  283.                         return 1;
  284.                     }
  285.                     case 3: // Adjust Toy Slot 4
  286.                     {
  287.                         EditAttachedObject(playerid, 4);
  288.                         return 1;
  289.                     }
  290.                 }
  291.             }
  292.         }
  293.     }
  294.     return 1;
  295. }
Advertisement
Add Comment
Please, Sign In to add comment