SHARE
TWEET

Untitled

a guest Feb 20th, 2020 72 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. new PackageWeapons[][WeaponData] = {
  2.  
  3.     {"9mm", WEAPON_COLT45, 100},
  4.     {"Silence 9mm", WEAPON_SILENCED, 100},
  5.     {"Desert Eagle", WEAPON_DEAGLE, 50},
  6.     {"Shotgun", WEAPON_SHOTGUN, 50},
  7.     {"Sawnoff Shotgun", WEAPON_SAWEDOFF, 50},
  8.     {"Combat Shotgun", WEAPON_SHOTGSPA, 50},
  9.     {"Micro SMG", WEAPON_UZI, 100},
  10.     {"SMG", WEAPON_MP5, 50},
  11.     {"AK47", WEAPON_AK47, 100},
  12.     {"M4", WEAPON_M4, 100},
  13.     {"Tec9", WEAPON_TEC9, 100},
  14.     {"Rifle", WEAPON_RIFLE, 40},
  15.     {"Sniper Rifle", WEAPON_SNIPER, 20},
  16.     {"Rocket Launcher", WEAPON_ROCKETLAUNCHER, 5},
  17.     {"Flamethrower", WEAPON_FLAMETHROWER, 40}, // btwn i got 2 ammo for FLAME h0w when i took package xD wtf
  18.     {"Minigun", WEAPON_MINIGUN, 20},
  19.     {"Grenade", WEAPON_GRENADE, 20},
  20.     {"Molotov Cocktail", WEAPON_MOLTOV, 20}
  21. };
  22.  
  23. new WeaponPackages[][PackagesData] = {
  24.  
  25.     {2832.0, 2405.0, 18.0},
  26.     {2819.0, 1663.0, 11.0},
  27.     {2725.0, 2727.0, 11.0},
  28.     {2649.0, 2733.0, 11.0},
  29.     {2148.0, 2721.0, 11.0},
  30.     {1345.0, 2367.0, 11.0},
  31.     {1625.0, 1944.0, 11.0},
  32.     {1569.0, 2150.0, 11.0},
  33.     {2072.0, 2370.0, 61.0},
  34.     {2225.0, 2530.0, 17.0},
  35.     {2337.0, 1806.0, 72.0},
  36.     {2575.0, 1562.0, 16.0},
  37.     {2243.0, 1132.0, 11.0},
  38.     {2676.0, 836.0, 22.0},
  39.     {1761.0, 591.0, 10.0},
  40.     {2809.0, 864.0, 21.0},
  41.     {1923.0, 1011.0, 22.0},
  42.     {1407.0, 1098.0, 11.0},
  43.     {1319.0, 1636.0, 10.6},
  44.     {1446.35, 1900.03, 11.0},
  45.     {1098.0, 1681.0, 7.0},
  46.     {924.0, 2138.0, 11.0},
  47.     {1155.0, 2341.0, 17.0},
  48.     {1646.0, 1349.0, 11.0},
  49.     {1781.0, 2072.0, 11.0},
  50.     {2478.0, 1182.0, 22.0},
  51.     {2510.0, -1723.0, 19.0},
  52.     {2538.0, -1630.0, 14.0},
  53.     {2551.33, -1740.0, 6.49},
  54.     {2428.0, -1214.0, 36.0},
  55.     {2766.0, -2182.0, 11.0},
  56.     {2142.0, -1804.0, 16.0},
  57.     {1764.0, -1930.0, 14.0},
  58.     {1214.0, -1816.0, 17.0},
  59.     {51740.0, -1231.0, 92.0},
  60.     {2266.0, -1028.0, 59.0},
  61.     {2463.0, -1061.0, 60.0},
  62.     {2047.0, -1406.0, 68.0},
  63.     {2213.0, -2283.0, 15.0},
  64.     {1463.0, -1013.0, 27.0},
  65.     {1308.97, -874.4, 40.0},
  66.     {1102.0, -661.0, 114.0},
  67.     {899.8012, -792.078, 102.0},
  68.     {338.0, -1875.0, 4.0},
  69.     {397.0, -1924.0, 8.0},
  70.     {886.0, -966.0, 37.0},
  71.     {1408.0, -2380.0, 14.0},
  72.     {1379.0, -2547.0, 14.0},
  73.     {2426.0, -1416.0, 24.0},
  74.     {2197.0, -2475.0, 14.0},
  75.     {2441.0, -1013.0, 54.0},
  76.     {-2678.0, -128.0, 4.0},
  77.     {-2212.0, 109.0, 35.0},
  78.     {-2903.0, 784.0, 35.0},
  79.     {-2665.0, 1452.0, 7.0},
  80.     {-2754.0, -400.0, 7.0},
  81.     {-2206.0, -23.0, 35.0},
  82.     {-1841.106, -74.2171, 14.7606},
  83.     {-1579.0, 29.45, 17.0},
  84.     {-2094.0, -488.0, 36.0},
  85.     {-1968.0, -923.0, 32.0},
  86.     {-1945.0, -1088.0, 31.0},
  87.     {-1700.0, 415.0, 7.0},
  88.     {-1386.0, 509.0, 4.0},
  89.     {-1679.0, 1410.0, 7.0},
  90.     {-2132.52, 189.2507, 35.5379},
  91.     {-1126.69, -150.82, 14.61},
  92.     {-1496.0, 591.0, 42.0},
  93.     {-2542.262, 922.2401, 67.1221},
  94.     {-2092.0, 1121.0, 54.0},
  95.     {-1629.0, 1167.0, 24.0},
  96.     {-1870.0, -1625.0, 22.0},
  97.     {-1627.0, -2692.0, 49.0},
  98.     {-2038.0, -2562.0, 31.0},
  99.     {-1035.0, -2258.0, 70.0},
  100.     {2366.0, 23.0, 28.0},
  101.     {2255.0, -74.0, 32.0},
  102.     {1296.0, 392.0, 20.0},
  103.     {262.0, 38.0, 2.0},
  104.     {-121.0, -232.0, 1.0},
  105.     {113.0, 1811.0, 18.0},
  106.     {36.0, 1372.0, 9.0},
  107.     {24.0, 969.0, 20.0},
  108.     {-170.0, 1025.0, 20.0},
  109.     {-639.0, 1181.0, 13.0},
  110.     {-585.0, 2714.0, 72.0},
  111.     {-742.0, 2752.0, 47.0},
  112.     {-932.02, 2649.92, 42.0},
  113.     {-1317.0, 2509.0, 87.0},
  114.     {-1474.0, 2577.0, 56.0},
  115.     {-2352.0, 2456.0, 6.0},
  116.     { -2520.0, 2293.0, 5.0},
  117.     {-1358.0, -2115.0, 30.0},
  118.     {119.0, 2409.0, 17.0},
  119.     {1284.894, 278.5705, 19.5547},
  120.     {2129.4, -2280.71, 14.42},
  121.     {2198.11, -1170.22, 33.5},
  122.     {935.744, -926.0453, 57.7642},
  123.     {255.0493, 84.0615, 1002.453},
  124.     {217.8, 76.4, 1005.047},
  125.     {263.2531, 109.7859, 1004.625},
  126.     {228.3176, 114.433, 999.0215},
  127.     {242.613, 196.3202, 1008.172},
  128.     {240.7765, 196.1124, 1008.172},
  129.     {-2539.918, -598.6152, 132.764},
  130.     {-2329.984, -165.3635, 35.2389},
  131.     {-2721.241, -318.8085, 7.5246},
  132.     {-2677.102, 234.9912, 4.1048},
  133.     {-2706.692, 375.8728, 5.0525},
  134.     {-2550.106, 657.286, 14.7319},
  135.     {-2791.248, 771.5468, 51.0904},
  136.     {-1770.815, 903.2556, 25.3894},
  137.     {-1713.006, 1368.239, 7.2664},
  138.     {-1851.317, 1302.291, 60.7553},
  139.     {-1635.026, 604.4713, 40.6377},
  140.     {-1976.483, 670.5043, 46.6039},
  141.     {-2038.409, 1111.406, 53.7928},
  142.     {-2048.803, 899.5274, 53.8866},
  143.     {-2292.47, 722.5441, 49.4265},
  144.     {-1977.916, 113.8457, 27.1096},
  145.     {-1528.144, 160.0232, 3.5142},
  146.     {-1771.261, -597.5884, 16.6287},
  147.     {2495.807, -1700.637, 1017.837},
  148.     {-601.4012, -1068.6, 23.6667},
  149.     {2820.013, -1426.519, 23.805},
  150.     {2790.343, -1427.489, 39.6258},
  151.     {2574.065, -1134.201, 64.6535},
  152.     {2423.892, -1117.452, 41.2464},
  153.     {1706.352, 1242.019, 34.2952},
  154.     {2492.051, 2398.377, 4.5293},
  155.     {2055.355, 2435.356, 40.3684},
  156.     {2293.686, 1982.286, 31.4335},
  157.     {244.98, 1859.185, 14.08},
  158.     {2529.724, -1678.563, 19.4225},
  159.     {2254.378, -2261.689, 14.3751},
  160.     {2015.744, 1004.045, 39.1}
  161. };
  162. //------------------------------------------------------------------------------------------------------
  163.  
  164.  
  165. if(!IsValidDynamicPickup(pickupid)) return 1;
  166.     if (Streamer_GetIntData(STREAMER_TYPE_PICKUP, pickupid, E_STREAMER_MODEL_ID) == 1276) {
  167.  
  168.         if(IsPlayerInAnyVehicle(playerid)) return 1;
  169.         if(IsPlayerInMinigame(playerid)) return 1;
  170.  
  171.         for(new i; i < sizeof(WeaponPackages); i++) {
  172.  
  173.             if(WeaponPackages[i][pickupID] == pickupid) {
  174.  
  175.                 new weaponid, ammo, found = 0, id = random(sizeof(PackageWeapons));
  176.                 for(new x; x <= 12; x++) {
  177.  
  178.                     GetPlayerWeaponData(playerid, x, weaponid, ammo);
  179.  
  180.                     //if(weaponid) continue;
  181.                     if(GetWeaponSlot(PackageWeapons[id][packageWeaponID]) == x)  {
  182.                         if(weaponid != 0 && ammo != 0)
  183.                         {
  184.                             if(Info[playerid][Premium] >= 2) AWH_GivePlayerWeapon(playerid, weaponid, PackageWeapons[id][packageWeaponAmmo] * 2);
  185.                             else AWH_GivePlayerWeapon(playerid, weaponid, PackageWeapons[id][packageWeaponAmmo]);
  186.                             new wname[36];
  187.                             new weaponid = PackageWeapons[id][packageWeaponID];
  188.                             GetWeaponName(weaponid, wname, sizeof(wname));
  189.                             format(string,sizeof(string),"Has picked (weapon :%s Ammo :%d)[Package]",wname,PackageWeapons[id][packageWeaponAmmo]);
  190.                             SavePlayerLog(playerid,string);
  191.                             found++;
  192.                             Info[playerid][Packages]++;
  193.                             PlayerPlaySound(playerid,1058,0.0,0.0,0.0);
  194.                             break;
  195.                         }
  196.                         else
  197.                         {
  198.                             if(Info[playerid][Premium] >= 2) AWH_GivePlayerWeapon(playerid, PackageWeapons[id][packageWeaponID], PackageWeapons[id][packageWeaponAmmo] * 2);
  199.                             else AWH_GivePlayerWeapon(playerid, PackageWeapons[id][packageWeaponID], PackageWeapons[id][packageWeaponAmmo]);
  200.                             new weaponidz = PackageWeapons[id][packageWeaponID];
  201.                             new wname[36];
  202.                             GetWeaponName(weaponidz, wname, sizeof(wname));
  203.                             format(string,sizeof(string),"Has picked (weapon :%s Ammo :%d)[Package]",wname,PackageWeapons[id][packageWeaponAmmo]);
  204.                             SavePlayerLog(playerid,string);
  205.  
  206.                             found++;
  207.                             Info[playerid][Packages]++;
  208.                             PlayerPlaySound(playerid,1058,0.0,0.0,0.0);
  209.                              //format(string, sizeof string, "~w~Package: %s", WeaponNames(weaponid));
  210.                              //GameTextForPlayer(playerid, string, 5000, 3);
  211.                             break;
  212.                         }
  213.  
  214.                     }
  215.                 }
  216.  
  217.                 if(found == 0)
  218.                 {
  219.                     new wname[36];
  220.                     new weaponids = PackageWeapons[id][packageWeaponID];
  221.                     GetWeaponName(weaponids, wname, sizeof(wname));
  222.                     if(Info[playerid][Premium] >= 2)
  223.                         AWH_GivePlayerWeapon(playerid, PackageWeapons[id][packageWeaponID], PackageWeapons[id][packageWeaponAmmo] * 2),format(string,sizeof(string),"Has picked (Weapon:%s ID:%s Ammo:%s)[Package]",wname, PackageWeapons[id][packageWeaponAmmo]),SavePlayerLog(playerid,string);
  224.                     else AWH_GivePlayerWeapon(playerid, PackageWeapons[id][packageWeaponID], PackageWeapons[id][packageWeaponAmmo]),format(string,sizeof(string),"Has picked (Weapon:%s ID:%s Ammo:%s)[Package]",wname, PackageWeapons[id][packageWeaponAmmo]),SavePlayerLog(playerid,string);
  225.  
  226.                     Info[playerid][Packages]++;
  227.                     PlayerPlaySound(playerid,1058,0.0,0.0,0.0);
  228.                     //format(string, sizeof string, "~w~Package: %s", PackageWeapons[id][packageWeapon]);
  229.                     //GameTextForPlayer(playerid, string, 5000, 3);
  230.                 }
  231.  
  232.                 mysql_format(mysql, string, sizeof string, "UPDATE `playersdata` SET `Packages` = %i WHERE `ID` = %i", Info[playerid][Packages], Info[playerid][ID]);
  233.                 mysql_tquery(mysql, string);
  234.  
  235.                 SetTimerEx("CreatePackage", 10 * 60000, 0, "i", i);
  236.                 DestroyDynamicPickup(WeaponPackages[i][pickupID]);
  237.                 ResetPickup(WeaponPackages[i][pickupID]);
  238.                 break;
  239.             }
  240.         }
  241.     }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top