Guest User

DraKoN

a guest
Apr 19th, 2010
1,864
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 26.76 KB | None | 0 0
  1. //
  2. // Base FS
  3. // Contains /pm /kick /ban commands.
  4. //
  5.  
  6. #include <a_samp>
  7. #include <pgd>
  8. #include "PAP"
  9. #include "../include/gl_common.inc"
  10.  
  11. #define ADMINFS_MESSAGE_COLOR 0xFF444499
  12. #define PM_INCOMING_COLOR     0xFFFF22AA
  13. #define PM_OUTGOING_COLOR     0xFFCC2299
  14.  
  15. forward Level(playerid);
  16. new favela[256];
  17. forward hospital(playerid);
  18.  
  19. //------------------------------------------------
  20.  
  21. public OnFilterScriptInit()
  22. {
  23.         print("Base Modificada By DraKoN");
  24.         /////////////////////////////////Objetos hospital///////////////////////////////
  25.         CreateObject(14671, 1920.316406, -2111.019531, -18.329149, 0.0000, 0.0000, 0.0000);
  26.         CreateObject(2146, 1944.652588, -2118.698730, -19.825382, 0.0000, 0.0000, 0.0000);
  27.         CreateObject(1801, 1941.835327, -2122.621094, -20.306990, 0.0000, 0.0000, 90.0001);
  28.         CreateObject(1801, 1941.803345, -2119.290527, -20.306990, 0.0000, 0.0000, 90.0000);
  29.         CreateObject(1801, 1941.794434, -2115.735107, -20.306990, 0.0000, 0.0000, 90.0000);
  30.         CreateObject(2514, 1943.145264, -2123.997070, -20.311726, 0.0000, 0.0000, 180.0000);
  31.         CreateObject(2517, 1942.205322, -2124.545898, -20.318745, 0.0000, 0.0000, 0.0000);
  32.         CreateObject(2596, 1945.220703, -2121.968262, -17.919817, 0.0000, 0.0000, 270.0000);
  33.         CreateObject(2632, 1942.522705, -2124.765625, -20.364603, 0.0000, 0.0000, 270.0000);
  34.         CreateObject(2842, 1939.127808, -2117.917969, -20.328419, 0.0000, 0.0000, 0.0000);
  35.         CreateObject(2596, 1945.143799, -2118.519287, -17.919847, 0.0000, 0.0000, 270.0000);
  36.         CreateObject(2596, 1945.196411, -2115.144287, -17.919802, 0.0000, 0.0000, 270.0000);
  37.         CreateObject(2225, 1938.298096, -2116.243408, -20.311415, 0.0000, 0.0000, 90.0000);
  38.         CreateObject(2225, 1938.476074, -2119.879883, -20.311415, 0.0000, 0.0000, 90.0000);
  39.         CreateObject(2225, 1938.521118, -2123.184326, -20.311415, 0.0000, 0.0000, 90.0000);
  40.         CreateObject(2190, 1938.570557, -2123.019287, -19.554298, 0.0000, 0.0000, 90.0000);
  41.         CreateObject(2190, 1938.473145, -2119.803711, -19.604298, 0.0000, 0.0000, 90.0000);
  42.         CreateObject(2190, 1938.301392, -2116.178955, -19.579298, 0.0000, 0.0000, 90.0000);
  43.         CreateObject(2294, 1945.059814, -2123.857910, -20.311970, 0.0000, 0.0000, 270.0000);
  44.         CreateObject(2842, 1939.164429, -2114.377686, -20.328419, 0.0000, 0.0000, 0.0000);
  45.         CreateObject(2842, 1939.084473, -2121.369385, -20.328419, 0.0000, 0.0000, 0.0000);
  46.         CreateObject(1998, 1935.449463, -2123.040527, -20.310932, 0.0000, 0.0000, 270.0000);
  47.         CreateObject(7191, 1937.824463, -2133.861084, -18.336254, 0.0000, 0.0000, 0.0000);
  48.         CreateObject(7191, 1961.554321, -2111.843994, -18.336254, 0.0000, 0.0000, 90.0000);
  49.         CreateObject(1491, 1939.418701, -2111.810791, -20.322823, 0.0000, 0.0000, 180.0000);
  50.         CreateObject(18084, 1939.069092, -2112.719482, -16.948509, 0.0000, 0.0000, 180.0000);
  51.         CreateObject(18084, 1942.698730, -2112.763184, -16.025635, 0.0000, 0.0000, 180.0000);
  52.         CreateObject(7191, 1912.582275, -2111.933105, -18.336254, 0.0000, 0.0000, 270.0000);
  53.         CreateObject(1491, 1937.745239, -2111.849365, -20.322823, 0.0000, 0.0000, 180.0000);
  54.         CreateObject(1491, 1934.720337, -2111.907715, -20.322823, 0.0000, 0.0000, 0.0000);
  55.         CreateObject(7191, 1914.986450, -2103.937256, -18.336254, 0.0000, 0.0000, 0.0000);
  56.         CreateObject(7191, 1930.189209, -2135.669922, -18.336254, 0.0000, 0.0000, 360.0000);
  57.         CreateObject(1491, 1930.197388, -2113.569092, -20.322823, 0.0000, 0.0000, 90.0000);
  58.         CreateObject(2007, 1932.147949, -2124.126953, -20.315323, 0.0000, 0.0000, 180.0000);
  59.         CreateObject(2007, 1931.255249, -2124.123047, -20.315323, 0.0000, 0.0000, 180.0000);
  60.         CreateObject(2000, 1930.540161, -2124.092529, -20.315323, 0.0000, 0.0000, 180.0000);
  61.         CreateObject(2161, 1937.727173, -2120.712158, -20.276737, 0.0000, 0.0000, 270.0000);
  62.         CreateObject(2162, 1937.727173, -2118.948242, -20.295057, 0.0000, 0.0000, 270.0000);
  63.         CreateObject(2164, 1937.659912, -2117.182373, -20.317530, 0.0000, 0.0000, 270.0000);
  64.         CreateObject(2167, 1937.699585, -2116.249512, -20.341284, 0.0000, 0.0000, 270.0000);
  65.         CreateObject(2200, 1930.431274, -2122.004395, -20.311747, 0.0000, 0.0000, 90.0000);
  66.         CreateObject(2164, 1930.342041, -2119.809570, -20.326447, 0.0000, 0.0000, 90.0000);
  67.         CreateObject(2167, 1930.360352, -2118.052979, -20.316284, 0.0000, 0.0000, 90.0000);
  68.         CreateObject(2161, 1937.727173, -2120.708252, -18.921749, 0.0000, 0.0000, 270.0000);
  69.         CreateObject(2162, 1930.291992, -2119.827148, -18.546812, 0.0000, 0.0000, 90.0000);
  70.         CreateObject(2163, 1935.516479, -2124.581055, -18.372620, 0.0000, 0.0000, 180.0000);
  71.         CreateObject(2008, 1933.625366, -2123.063721, -20.310932, 0.0000, 0.0000, 0.0000);
  72.         CreateObject(1806, 1934.677612, -2123.904297, -20.291283, 0.0000, 0.0000, 0.0000);
  73.         CreateObject(1806, 1935.804810, -2123.996582, -20.291283, 0.0000, 0.0000, 270.0000);
  74.         CreateObject(3383, 1920.587036, -2108.663818, -20.310932, 0.0000, 0.0000, 0.0000);
  75.         CreateObject(3383, 1920.568359, -2105.134033, -20.310932, 0.0000, 0.0000, 180.0000);
  76.         CreateObject(3383, 1926.522217, -2105.201660, -20.310932, 0.0000, 0.0000, 180.0000);
  77.         CreateObject(3383, 1926.520874, -2108.529053, -20.310932, 0.0000, 0.0000, 0.0000);
  78.         CreateObject(1708, 1930.946655, -2115.770752, -20.310976, 0.0000, 0.0000, 90.0000);
  79.         CreateObject(1708, 1930.964111, -2117.300781, -20.310976, 0.0000, 0.0000, 90.0000);
  80.         CreateObject(1722, 1934.053345, -2112.539063, -20.310730, 0.0000, 0.0000, 180.0000);
  81.         CreateObject(1722, 1933.075195, -2112.566162, -20.310730, 0.0000, 0.0000, 180.0000);
  82.         CreateObject(1722, 1937.521362, -2115.071045, -20.310730, 0.0000, 0.0000, 90.0000);
  83.         CreateObject(1722, 1937.506592, -2114.116699, -20.310730, 0.0000, 0.0000, 90.0000);
  84.         CreateObject(2146, 1930.821533, -2103.184570, -19.825382, 0.0000, 0.0000, 270.0000);
  85.         CreateObject(2146, 1923.793457, -2103.090088, -19.825382, 0.0000, 0.0000, 270.0000);
  86.         CreateObject(2146, 1922.961548, -2111.129395, -19.825382, 0.0000, 0.0000, 270.0000);
  87.         CreateObject(2008, 1915.549927, -2106.774414, -20.310932, 0.0000, 0.0000, 0.0000);
  88.         CreateObject(2008, 1917.386475, -2107.597168, -20.310932, 0.0000, 0.0000, 270.0000);
  89.         CreateObject(2008, 1917.374878, -2109.526611, -20.310932, 0.0000, 0.0000, 270.0000);
  90.         CreateObject(2190, 1928.039795, -2105.195313, -19.259876, 0.0000, 0.0000, 45.0000);
  91.         CreateObject(2190, 1927.658325, -2108.213135, -19.259876, 0.0000, 0.0000, 135.0000);
  92.         CreateObject(2190, 1921.692017, -2108.441162, -19.259876, 0.0000, 0.0000, 135.0000);
  93.         CreateObject(2190, 1921.979736, -2105.015381, -19.259876, 0.0000, 0.0000, 45.0000);
  94.         CreateObject(2164, 1927.085083, -2100.907227, -20.317530, 0.0000, 0.0000, 0.0000);
  95.         CreateObject(2164, 1915.134766, -2103.808838, -20.317530, 0.0000, 0.0000, 90.0000);
  96.         CreateObject(2164, 1915.130371, -2105.539551, -20.317530, 0.0000, 0.0000, 90.0000);
  97.         CreateObject(2162, 1916.946899, -2102.523438, -20.315102, 0.0000, 0.0000, 0.0000);
  98.         CreateObject(2162, 1915.080322, -2110.733887, -20.255934, 0.0000, 0.0000, 90.0000);
  99.         CreateObject(2164, 1915.132446, -2108.978271, -20.317530, 0.0000, 0.0000, 90.0000);
  100.         CreateObject(7191, 1932.774170, -2088.226563, -18.336254, 0.0000, 0.0000, 180.0001);
  101.         CreateObject(1491, 1932.853760, -2111.863037, -20.322823, 0.0000, 0.0000, 90.0000);
  102.         CreateObject(2371, 1920.384155, -2101.982422, -18.938208, 0.0000, 275.7753, 90.0000);
  103.         CreateObject(2381, 1919.809448, -2103.027100, -19.436613, 0.0000, 0.0000, 0.0000);
  104.         CreateObject(2394, 1919.782471, -2102.995850, -18.812122, 0.0000, 0.0000, 0.0000);
  105.         CreateObject(7191, 1959.890015, -2111.812012, -14.454750, 0.0000, 0.0000, 90.0000);
  106.         CreateObject(7191, 1915.707642, -2111.859863, -14.511251, 0.0000, 0.0000, 270.0000);
  107.         CreateObject(1726, 1944.788208, -2103.902344, -20.318518, 0.0000, 0.0000, 270.0000);
  108.         CreateObject(1726, 1944.766479, -2107.554688, -20.318518, 0.0000, 0.0000, 270.0000);
  109.         CreateObject(1727, 1942.064453, -2103.629395, -20.318504, 0.0000, 0.0000, 0.0000);
  110.         CreateObject(1726, 1933.975952, -2103.002930, -20.318518, 0.0000, 0.0000, 0.0000);
  111.         CreateObject(1726, 1933.392578, -2105.606445, -20.318518, 0.0000, 0.0000, 90.0000);
  112.         CreateObject(1726, 1933.367676, -2107.885742, -20.318518, 0.0000, 0.0000, 90.0000);
  113.         CreateObject(7191, 1945.648193, -2124.174805, -18.336254, 0.0000, 0.0000, 180.0000);
  114.         CreateObject(7191, 1937.120728, -2102.420654, -18.336254, 0.0000, 0.0000, 270.0000);
  115.         CreateObject(7191, 1924.752808, -2102.423828, -14.404360, 0.0000, 0.0000, 270.0000);
  116.         CreateObject(7191, 1932.470093, -2124.592285, -18.336254, 0.0000, 0.0000, 90.0000);
  117.         CreateObject(2762, 1942.792480, -2108.818115, -19.905745, 0.0000, 0.0000, 270.0000);
  118.         CreateObject(2763, 1942.559814, -2105.382568, -19.905745, 0.0000, 0.0000, 0.0000);
  119.         CreateObject(2762, 1936.399170, -2105.094238, -19.905745, 0.0000, 0.0000, 0.0000);
  120.         CreateObject(2762, 1935.838989, -2106.598389, -19.905745, 0.0000, 0.0000, 270.0000);
  121.         CreateObject(2762, 1939.278687, -2107.175293, -19.905745, 0.0000, 0.0000, 270.0000);
  122.         CreateObject(2762, 1938.222412, -2107.176758, -19.905745, 0.0000, 0.0000, 270.0000);
  123.         CreateObject(1727, 1939.295410, -2109.203125, -20.318504, 0.0000, 0.0000, 180.0000);
  124.         CreateObject(1727, 1938.331421, -2105.366455, -20.318504, 0.0000, 0.0000, 0.0000);
  125.         CreateObject(1727, 1940.374634, -2106.602783, -20.318504, 0.0000, 0.0000, 270.0000);
  126.         CreateObject(2164, 1939.757080, -2102.644043, -20.317530, 0.0000, 0.0000, 0.0000);
  127.         CreateObject(2164, 1938.021973, -2102.647461, -20.317530, 0.0000, 0.0000, 0.0000);
  128.         CreateObject(2162, 1938.975342, -2102.545166, -18.484613, 0.0000, 0.0000, 0.0000);
  129.         CreateObject(2816, 1939.097290, -2106.793701, -19.487812, 0.0000, 0.0000, 0.0000);
  130.         CreateObject(2813, 1938.396362, -2107.639404, -19.487682, 0.0000, 0.0000, 0.0000);
  131.         CreateObject(2826, 1935.880615, -2105.389648, -19.487720, 0.0000, 0.0000, 0.0000);
  132.         CreateObject(2827, 1942.507446, -2105.374756, -19.473944, 0.0000, 0.0000, 0.0000);
  133.         CreateObject(2829, 1942.880981, -2108.282715, -19.487682, 0.0000, 0.0000, 337.5000);
  134.         CreateObject(2853, 1935.820923, -2107.167480, -19.487741, 0.0000, 0.0000, 0.0000);
  135.         CreateObject(2855, 1933.463257, -2107.478027, -19.798683, 0.0000, 0.0000, 337.5000);
  136.         CreateObject(2297, 1941.693237, -2111.447021, -20.316912, 0.0000, 0.0000, 135.0000);
  137.         CreateObject(18084, 1936.491089, -2112.775635, -17.060766, 0.0000, 0.0000, 180.0000);
  138.         CreateObject(18084, 1935.038696, -2112.785889, -17.063675, 0.0000, 0.0000, 180.0000);
  139.         CreateObject(18084, 1933.684326, -2110.609619, -17.010744, 0.0000, 0.0000, 270.0000);
  140.         CreateObject(18084, 1931.040161, -2113.303223, -16.951126, 0.0000, 0.0000, 270.0000);
  141.         CreateObject(12842, 1924.250854, -2119.015381, -19.856260, 0.0000, 0.0000, 180.0000);
  142.         CreateObject(2457, 1918.963501, -2113.575195, -20.311718, 0.0000, 0.0000, 90.0000);
  143.         CreateObject(2457, 1918.974854, -2115.503418, -20.311718, 0.0000, 0.0000, 90.0000);
  144.         CreateObject(2457, 1918.996948, -2117.375732, -20.311718, 0.0000, 0.0000, 90.0000);
  145.         CreateObject(2454, 1918.842529, -2118.440186, -20.315512, 0.0000, 0.0000, 0.0000);
  146.         CreateObject(2455, 1917.941650, -2118.427979, -20.300747, 0.0000, 0.0000, 0.0000);
  147.         CreateObject(2455, 1917.013184, -2118.421387, -20.300747, 0.0000, 0.0000, 0.0000);
  148.         CreateObject(1514, 1917.999390, -2118.455078, -19.006407, 0.0000, 0.0000, 0.0000);
  149.         CreateObject(955, 1918.965454, -2123.842285, -19.907885, 0.0000, 0.0000, 180.0000);
  150.         CreateObject(956, 1917.437866, -2123.937500, -19.906919, 0.0000, 0.0000, 191.2500);
  151.         CreateObject(2431, 1915.089111, -2114.595459, -17.892643, 0.0000, 0.0000, 90.0000);
  152.         CreateObject(2430, 1915.089111, -2118.682373, -17.928322, 0.0000, 0.0000, 90.0000);
  153.         CreateObject(2431, 1915.662354, -2112.035889, -17.884180, 0.0000, 0.0000, 0.0000);
  154.         CreateObject(1481, 1915.464966, -2112.625977, -19.607807, 0.0000, 0.0000, 90.0000);
  155.         CreateObject(2130, 1915.601563, -2114.627930, -20.311216, 0.0000, 0.0000, 90.0000);
  156.         CreateObject(2127, 1915.581055, -2116.603027, -20.311970, 0.0000, 0.0000, 90.0000);
  157.         CreateObject(1481, 1915.498413, -2117.738281, -19.607807, 0.0000, 0.0000, 90.0000);
  158.         CreateObject(1649, 1923.880371, -2124.462891, -18.457897, 0.0000, 0.0000, 180.0000);
  159.         CreateObject(1649, 1915.169312, -2106.339844, -18.275267, 0.0000, 0.0000, 90.0000);
  160.         CreateObject(1649, 1927.627075, -2102.599121, -18.316463, 0.0000, 0.0000, 360.0000);
  161.         CreateObject(1649, 1945.530762, -2105.665771, -18.132938, 0.0000, 0.0000, 269.9999);
  162.         CreateObject(1649, 1941.359497, -2124.473145, -18.169756, 0.0000, 0.0000, 180.0001);
  163.         CreateObject(955, 1933.301880, -2109.120850, -19.907885, 0.0000, 0.0000, 90.0000);
  164.         return 1;
  165. }
  166. /////////////////////////////////////////////////////////////////////
  167. public OnPlayerDeath(playerid, killerid, reason)
  168. {
  169.     ApplyAnimation(playerid, "BEACH", "bather", 4.0, 1, 0, 0, 0, 0);
  170.     SetTimer("hospital",8000,false);
  171.     TogglePlayerControllable(playerid, 0);
  172.     SendClientMessage (playerid,PM_OUTGOING_COLOR, "Você Morreu Esta em Coma no Hospital");
  173.     SetPlayerFacingAngle(playerid,322.2638);
  174.     SetPlayerPos(playerid,1939.8497,-2118.8464,-18.6666);
  175.     if(GetPlayerWeapon(killerid) == 38) Ban(killerid); //Ban if they have a minigun
  176.     return 1;
  177. }
  178. //////////////////////////////Ao Conectar/////////////////////////////////////
  179. public OnPlayerConnect(playerid)
  180. {
  181.    
  182.     return 1;
  183. }
  184. //////////////////////////////Ao Desconectar////////////////////////////////////
  185. public OnPlayerDisconnect(playerid, reason)
  186. {
  187.  
  188.     return 1;
  189. }
  190. //////////////////////////////Level/////////////////////////////////////////////
  191. public Level(playerid)
  192. {
  193.  
  194. SetPlayerScore(playerid, GetPlayerScore(playerid) + 1);
  195. SendClientMessage(playerid,PM_OUTGOING_COLOR,"Você Upou seu level Parabens.");
  196. }
  197. ////////////////////////////AO IR HOSPITAL//////////////////////////////////////
  198. public hospital(playerid)
  199. {
  200. TogglePlayerControllable(playerid, 1);
  201. return 1;
  202. }
  203. //-----------------------------------------------
  204. ////////////////////////OnPlayerSpawn///////////////////////////////////////
  205. public OnPlayerSpawn(playerid)
  206. {
  207. SetTimer("Level",60*60*1000,false);
  208. }
  209.  
  210. ////////////////////COMANDOS////////////////////////////////////////////////////
  211. public OnPlayerCommandText(playerid, cmdtext[])
  212. {
  213.  
  214.     new cmd[256];
  215.     new tmp[256];
  216.     new Message[256];
  217.     new gMessage[256];
  218.     new pName[MAX_PLAYER_NAME+1];
  219.     new iName[MAX_PLAYER_NAME+1];
  220.     new idx;
  221.     cmd = strtok(cmdtext, idx);
  222.  
  223.     ///-------------------------------------------------------------------------
  224.     if(strcmp("/pm", cmd, true) == 0)
  225.     {
  226.         tmp = strtok(cmdtext,idx);
  227.        
  228.         if(!strlen(tmp) || strlen(tmp) > 5) {
  229.             SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Usage: /pm (id) (message)");
  230.             return 1;
  231.         }
  232.        
  233.         new id = strval(tmp);
  234.         gMessage = strrest(cmdtext,idx);
  235.        
  236.         if(!strlen(gMessage)) {
  237.             SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Usage: /pm (id) (message)");
  238.             return 1;
  239.         }
  240.        
  241.         if(!IsPlayerConnected(id)) {
  242.             SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"/pm : Bad player ID");
  243.             return 1;
  244.         }
  245.        
  246.         if(playerid != id) {
  247.             GetPlayerName(id,iName,sizeof(iName));
  248.             GetPlayerName(playerid,pName,sizeof(pName));
  249.             format(Message,sizeof(Message),">> %s(%d): %s",iName,id,gMessage);
  250.             SendClientMessage(playerid,PM_OUTGOING_COLOR,Message);
  251.             format(Message,sizeof(Message),"** %s(%d): %s",pName,playerid,gMessage);
  252.             SendClientMessage(id,PM_INCOMING_COLOR,Message);
  253.             PlayerPlaySound(id,1085,0.0,0.0,0.0);
  254.            
  255.             printf("PM: %s",Message);
  256.  
  257.         }
  258.         else {
  259.             SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"You cannot PM yourself");
  260.         }
  261.         return 1;
  262.         }
  263.  
  264.  
  265. //---------------------ANIMAÇÕES---------------------------------------------
  266.     if(strcmp("/renderse", cmd, true) == 0)
  267.     {
  268.         SetPlayerSpecialAction(playerid, 10);
  269.         return 1;
  270.     }
  271.     if(strcmp("/ligar", cmd, true) == 0)
  272.     {
  273.         SetPlayerSpecialAction(playerid, 11);
  274.         return 1;
  275.     }
  276.     if(strcmp("/desligar", cmd, true) == 0)
  277.     {
  278.         SetPlayerSpecialAction(playerid, 13);
  279.         return 1;
  280.     }
  281.     if(strcmp("/bebado", cmd, true) == 0)
  282.     {
  283.         ApplyAnimation(playerid, "PED", "WALK_DRUNK", 4.0, 1, 1, 1, 1, 0);
  284.         return 1;
  285.     }
  286.     if(strcmp("/bomba", cmd, true) == 0)
  287.     {
  288.         ClearAnimations(playerid);
  289.         ApplyAnimation(playerid, "BOMBER", "BOM_Plant", 4.0, 0, 0, 0, 0, 0);
  290.         return 1;
  291.     }
  292.     if(strcmp("/apontar", cmd, true) == 0)
  293.     {
  294.         ApplyAnimation(playerid, "ped", "ARRESTgun", 4.0, 0, 1, 1, 1, -1);
  295.         return 1;
  296.     }
  297.     if(strcmp("/merda", cmd, true) == 0)
  298.     {
  299.         ApplyAnimation(playerid, "RAPPING", "Laugh_01", 4.0, 0, 0, 0, 0, 0);
  300.         return 1;
  301.     }
  302.     if(strcmp("/mascararse", cmd, true) == 0)
  303.     {
  304.         ApplyAnimation(playerid, "SHOP", "ROB_Shifty", 4.0, 0, 0, 0, 0, 0);
  305.         return 1;
  306.     }
  307.     if(strcmp("/roubar", cmd, true) == 0)
  308.     {
  309.         ApplyAnimation(playerid, "SHOP", "ROB_Loop_Threat", 4.0, 1, 0, 0, 0, 0);
  310.         return 1;
  311.     }
  312.     if(strcmp("/cruzarb", cmd, true) == 0)
  313.     {
  314.         ApplyAnimation(playerid, "COP_AMBIENT", "Coplook_loop", 4.0, 0, 1, 1, 1, -1);
  315.         return 1;
  316.     }
  317.     if(strcmp("/deitar", cmd, true) == 0)
  318.     {
  319.         ApplyAnimation(playerid, "BEACH", "bather", 4.0, 1, 0, 0, 0, 0);
  320.         return 1;
  321.     }
  322.     if(strcmp("/abaixar", cmd, true) == 0)
  323.     {
  324.         ApplyAnimation(playerid, "ped", "cower", 3.0, 1, 0, 0, 0, 0);
  325.         return 1;
  326.     }
  327.     if(strcmp("/vomitar", cmd, true) == 0)
  328.     {
  329.         ApplyAnimation(playerid, "FOOD", "EAT_Vomit_P", 3.0, 0, 0, 0, 0, 0);
  330.         return 1;
  331.     }
  332.     if(strcmp("/comer", cmd, true) == 0)
  333.     {
  334.         ApplyAnimation(playerid, "FOOD", "EAT_Burger", 3.0, 0, 0, 0, 0, 0);
  335.         return 1;
  336.     }
  337.     if(strcmp("/rap", cmd, true) == 0)
  338.     {
  339.         ApplyAnimation(playerid, "ON_LOOKERS", "wave_loop", 4.0, 1, 0, 0, 0, 0);
  340.         return 1;
  341.     }
  342.     if(strcmp("/passaramao", cmd, true) == 0)
  343.     {
  344.         ApplyAnimation(playerid, "SWEET", "sweet_ass_slap", 4.0, 0, 0, 0, 0, 0);
  345.         return 1;
  346.     }
  347.     if(strcmp("/cobrar", cmd, true) == 0)
  348.     {
  349.         ApplyAnimation(playerid, "DEALER", "DEALER_DEAL", 4.0, 0, 0, 0, 0, 0);
  350.         return 1;
  351.     }
  352.     if(strcmp("/overdose", cmd, true) == 0)
  353.     {
  354.         ApplyAnimation(playerid, "CRACK", "crckdeth2", 4.0, 1, 0, 0, 0, 0);
  355.         return 1;
  356.     }
  357.     if(strcmp("/fumar", cmd, true) == 0)
  358.     {
  359.         ApplyAnimation(playerid, "SMOKING", "M_smklean_loop", 4.0, 1, 0, 0, 0, 0);
  360.         return 1;
  361.     }
  362.     if(strcmp("/fumar2", cmd, true) == 0)
  363.     {
  364.         ApplyAnimation(playerid, "SMOKING", "F_smklean_loop", 4.0, 1, 0, 0, 0, 0);
  365.         return 1;
  366.     }
  367.     if(strcmp("/sentar", cmd, true) == 0)
  368.     {
  369.         ApplyAnimation(playerid, "BEACH", "ParkSit_M_loop", 4.0, 1, 0, 0, 0, 0);
  370.         return 1;
  371.     }
  372.     if(strcmp("/conversar", cmd, true) == 0)
  373.     {
  374.         ApplyAnimation(playerid, "PED", "IDLE_CHAT", 4.0, 0, 0, 0, 0, 0);
  375.         return 1;
  376.     }
  377.     if(strcmp("/fodase", cmd, true) == 0)
  378.     {
  379.         ApplyAnimation(playerid, "PED", "fucku", 4.0, 0, 0, 0, 0, 0);
  380.         return 1;
  381.     }
  382.     if(strcmp("/taichi", cmd, true) == 0)
  383.     {
  384.         ApplyAnimation(playerid, "PARK", "Tai_Chi_Loop", 4.0, 1, 0, 0, 0, 0);
  385.         return 1;
  386.     }
  387.     if(strcmp("/observar", cmd, true) == 0)
  388.     {
  389.         ApplyAnimation(playerid, "BAR", "dnk_stndF_loop", 4.0, 1, 0, 0, 0, 0);
  390.         return 1;
  391.     }
  392. //---------------------Lista Animações------------------------------------
  393.     if(strcmp("/animes", cmd, true) == 0)
  394.     {
  395.     SendClientMessage(playerid,  ADMINFS_MESSAGE_COLOR, "Lista de Animes:");
  396.     SendClientMessage(playerid,  ADMINFS_MESSAGE_COLOR, "/renderse /ligar /desligar /bebado /bomba /apontar /merda /mascararse");
  397.     SendClientMessage(playerid,  ADMINFS_MESSAGE_COLOR, "/roubar /cruzarb /deitar /abaixar /vomitar /comer /rap /passaramao");
  398.     SendClientMessage(playerid,  ADMINFS_MESSAGE_COLOR, "/cobrar /overdose /fumar /fumar2 /sentar /conversar /fodase /taichi");
  399.     SendClientMessage(playerid,  ADMINFS_MESSAGE_COLOR, "/observar ");
  400.     return 1;
  401.     }
  402.  
  403.     //-----------------------------Admins Online--------------------------
  404.     if(strcmp(cmdtext, "/admins", true) == 0){
  405.     new Jogador[24];
  406.     new count = 0;
  407.     new msg[120];
  408.     for(new i=0; i<MAX_PLAYERS; i++){
  409.     if(IsPlayerConnected(i) && IsPlayerAdmin(i)){
  410.     GetPlayerName(i,Jogador,24);
  411.     format(msg,sizeof(msg),"Admins Online: %s", Jogador);
  412.     SendClientMessage(playerid, 0x000FFFAA, msg);
  413.     count++;
  414.     }
  415.     }
  416.     if(count == 0){
  417.     SendClientMessage(playerid,  ADMINFS_MESSAGE_COLOR, "Não tem nenhum adm online agora! ");
  418.     }
  419.     return 1;
  420.     }
  421.  
  422.     //-------------------------------------------------------------------------
  423.     if(strcmp("/hospital", cmd, true) == 0)
  424.     {
  425.     SetPlayerPos(playerid,1935.4089,-2110.2100,-19.3109);
  426.     SendClientMessage(playerid,PM_OUTGOING_COLOR ,"Bem Vindo ao Hospital");
  427.     return 1;
  428.     }
  429.     //-------------------------------------------------------------------------
  430.     if(strcmp("/favelatraficante", cmd, true) == 0)
  431.     {
  432.     SendClientMessage(playerid,PM_OUTGOING_COLOR ,"Bem Vindo a Favela");
  433.     favela[playerid] = 1;
  434.     SetPlayerPos(playerid,2237.6868,-1079.4060,41.6102);
  435.     SetPlayerSkin(playerid, 268);
  436.     ResetPlayerWeapons(0);
  437.     GivePlayerWeapon(playerid, 26, 9999);
  438.     GivePlayerWeapon(playerid, 24, 9999);
  439.     GivePlayerWeapon(playerid, 31, 9999);
  440.     GivePlayerWeapon(playerid, 32, 9999);
  441.     return 1;
  442.     }
  443.     //-------------------------------------------------------------------------
  444.     if(strcmp("/favelapolicial", cmd, true) == 0)
  445.     {
  446.     SendClientMessage(playerid,PM_OUTGOING_COLOR ,"Bem Vindo a Favela");
  447.     favela[playerid] = 1;
  448.     SetPlayerPos(playerid,2237.6868,-1079.4060,41.6102);
  449.     SetPlayerSkin(playerid, 281);
  450.     ResetPlayerWeapons(0);
  451.     GivePlayerWeapon(playerid, 26, 9999);
  452.     GivePlayerWeapon(playerid, 24, 9999);
  453.     GivePlayerWeapon(playerid, 31, 9999);
  454.     GivePlayerWeapon(playerid, 32, 9999);
  455.     return 1;
  456.     }
  457.     //-------------------------------------------------------------------------
  458.     if(strcmp( cmd, "/luta", true ) == 0)
  459.     {
  460.     new name[128];
  461.     tmp = strtok(cmdtext, idx);
  462.     new style = strval(tmp);
  463.     SetPlayerFightingStyle(playerid, style);
  464.     GetPlayerName(playerid,name,128);
  465.     format(tmp, 256, "(%s) ( mudou estilo de luta para %d", name, style);
  466.     SendClientMessageToAll(0x4499CCFF,tmp);
  467.     return 1;
  468.     }
  469.     //-------------------------------------------------------------------------
  470.     if(strcmp("/morre", cmd, true) == 0)
  471.     {
  472.     SetPlayerHealth(playerid, 0);
  473.     SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Voce Se Matou!");
  474.     return 1;
  475.     }
  476.     //-------------------------------------------------------------------------
  477.     if(strcmp("/reparar", cmd, true) == 0)
  478.     {
  479.     RepairVehicle (playerid);
  480.     SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Carro Reparado");
  481.     return 1;
  482.     }
  483.     //-------------------------------------------------------------------------
  484.     if(strcmp("/vida", cmd, true) == 0)
  485.     {
  486.     SetPlayerHealth(playerid, 100);
  487.     SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Ganhou Vida para 100!!!");
  488.     return 1;
  489.     }
  490.     //-------------------------------------------------------------------------
  491.     if(strcmp("/colete", cmd, true) == 0)
  492.     {
  493.     SetPlayerArmour(playerid,100);
  494.     SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Ganhaste Colete");
  495.     return 1;
  496.     }
  497.     //-------------------------------------------------------------------------
  498.     if(strcmp("/bebado", cmd, true) == 0)
  499.     {
  500.     SetPlayerDrunkLevel(playerid, 98);
  501.     SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Seu Cachacero");
  502.     return 1;
  503.     }
  504.     //-------------------------------------------------------------------------
  505.     if(strcmp("/normal", cmd, true) == 0)
  506.     {
  507.     SetPlayerDrunkLevel(playerid,1);
  508.     SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Passou a Ressaca");
  509.     return 1;
  510.     }
  511.     //-------------------------------------------------------------------------
  512.     if(strcmp("/gastar", cmd, true) == 0)
  513.     {
  514.     ResetPlayerMoney(playerid);
  515.     SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Você Gastaste teu dinheiro em Puta,Cachassa, e Maquinas Cacaniqueis");
  516.     return 1;
  517.     }
  518.  
  519.     ///-------------------------------------------------------------------------
  520.     if(strcmp("/kick", cmd, true) == 0)
  521.     {
  522.         if(IsPlayerAdmin(playerid)) {
  523.             tmp = strtok(cmdtext,idx);
  524.             if(!strlen(tmp) || strlen(tmp) > 5) {
  525.                 return SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Usage: /kick (id) [reason]");
  526.             }
  527.            
  528.             new id = strval(tmp);
  529.  
  530.             if(!IsPlayerConnected(id)) {
  531.                 SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"/kick : Bad player ID");
  532.                 return 1;
  533.             }
  534.            
  535.             gMessage = strrest(cmdtext,idx);
  536.            
  537.             GetPlayerName(id,iName,sizeof(iName));
  538.             SendClientMessage(id,ADMINFS_MESSAGE_COLOR,"-- You have been kicked from the server.");
  539.  
  540.             if(strlen(gMessage) > 0) {
  541.                 format(Message,sizeof(Message),"Reason: %s",gMessage);
  542.                 SendClientMessage(id,ADMINFS_MESSAGE_COLOR,Message);
  543.             }
  544.            
  545.             format(Message,sizeof(Message),">> %s(%d) has been kicked.",iName,id);
  546.             SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,Message);
  547.            
  548.             Kick(id);
  549.             return 1;
  550.         } else {
  551.             SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"/kick : You are not an admin");
  552.             return 1;
  553.         }
  554.     }
  555.  
  556.     //-------------------------------------------------------------------------
  557.     if(strcmp("/ban", cmd, true) == 0)
  558.     {
  559.         if(IsPlayerAdmin(playerid)) {
  560.             tmp = strtok(cmdtext,idx);
  561.             if(!strlen(tmp) || strlen(tmp) > 5) {
  562.                 return SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"Usage: /ban (id) [reason]");
  563.             }
  564.  
  565.             new id = strval(tmp);
  566.  
  567.             if(!IsPlayerConnected(id)) {
  568.                 SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"/ban : Bad player ID");
  569.                 return 1;
  570.             }
  571.  
  572.             gMessage = strrest(cmdtext,idx);
  573.  
  574.             GetPlayerName(id,iName,sizeof(iName));
  575.             SendClientMessage(id,ADMINFS_MESSAGE_COLOR,"-- You have been banned from the server.");
  576.  
  577.             if(strlen(gMessage) > 0) {
  578.                 format(Message,sizeof(Message),"Reason: %s",gMessage);
  579.                 SendClientMessage(id,ADMINFS_MESSAGE_COLOR,Message);
  580.             }
  581.  
  582.             format(Message,sizeof(Message),">> %s(%d) has been banned.",iName,id);
  583.             SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,Message);
  584.  
  585.             Ban(id);
  586.             return 1;
  587.         } else {
  588.             SendClientMessage(playerid,ADMINFS_MESSAGE_COLOR,"/ban : You are not an admin");
  589.             return 1;
  590.         }
  591.     }
  592.  
  593.     return 0;
  594. }
  595. /////////////////////////////////strktok Usado nos Comandos////////////////////////////////
  596. strtok(const string[], &index)
  597. {
  598.     new length = strlen(string);
  599.     while ((index < length) && (string[index] <= ' '))
  600.     {
  601.         index++;
  602.     }
  603.  
  604.     new offset = index;
  605.     new result[20];
  606.     while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1)))
  607.     {
  608.         result[index - offset] = string[index];
  609.         index++;
  610.     }
  611.     result[index - offset] = EOS;
  612.     return result;
  613. }
Advertisement
Add Comment
Please, Sign In to add comment