Advertisement
Surprise6555

Untitled

May 26th, 2016
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 8.88 KB | None | 0 0
  1. os.loadAPI("crate")
  2. --ZQFRMy0D
  3. function RandomNumbers()
  4.   Y1 = math.random(42)
  5.   Y2 = math.random(42)
  6.   Y3 = math.random(42)
  7.   Y4 = math.random(42)
  8.   Y5 = math.random(42)
  9.   Y6 = math.random(42)
  10.   Y7 = math.random(42)
  11.   Y8 = math.random(42)
  12.   Y9 = math.random(42)
  13.   X = math.random(13)
  14.   X1 = math.random(13)
  15.   Z1 = math.random(42)
  16.   Z2 = math.random(42)
  17.   Z3 = math.random(42)
  18.   Z4 = math.random(42)
  19.   Z5 = math.random(42)
  20.   Z6 = math.random(42)
  21.   Z7 = math.random(42)
  22.   Z8 = math.random(42)
  23.   Z9 = math.random(42)
  24.   A = math.random(18)
  25.   A1 = math.random(18)
  26.   A2 = math.random(18)
  27.   A3 = math.random(18)
  28.   B = math.random(34)
  29.   B1 = math.random(34)
  30.   B2 = math.random(34)
  31.   B3 = math.random(34)
  32.   B4 = math.random(34)
  33.   B5 = math.random(34)
  34.   C = math.random(26)
  35.   D = math.random(27)
  36.  
  37.  
  38.  
  39. -- First, you need to make a table with all the items.
  40. Cache1Melee = {6099, 6056, 6072,  6109, 6221, 6069, 6125, 6139, 6178, 6321, 6300, 6129, 6150}
  41. Cache1Misc = {6168, 6079, 6090, 6184, 6181, 6123, 6390, 6137, 5460, 6055, 5461, 4845, 4698, 4517, 4518, 4516, 5227, 5228}
  42. Cache1Gear = {6094, 6253, 6067, 6070, 6083, 6187, 6301,  6250, 6245, 6133, 6217, 6372, 6102, 6237, 6191, 6142, 6334, 6216, 6310, 6089, 5490, 6215, 6261, 6317, 6203, 6254, 6246, 5538, 6210, 6353, 6324, 6062, 5493, 5491, 5494, 5492, 5488, 5486, 5489, 5487, 310, 311, 312, 313, 5484, 5482, 5485, 5483, 5617, 5615, 5618, 5616, 5481, 6141}
  43. Cache1Guns = {4985, 4985, 5107, 5221, 5178, 5199, 5209, 5193, 5186, 5186, 4957, 4957, 5140,  5196,  5194,  5222, 5187,  5179,  5188, 4979, 4981, 5212, 5195, 4995, 4962, 5213, 5190, 5189, 5177, 5197, 5198, 5204, 5203, 5157, 4960, 4968, 5176, 5182, 5192, 5181}
  44. Cache1Ammo = { 4593, 4594, 4735, 4764, 4765, 4765,  4768, 4792,  4766, 4767, 4567, 4566, 4795, 4790, 4790, 4791, 4775, 4776, 4776, 4586, 4588, 4763, 4762, 4604, 4572, 4775, 4784, 4784, 4784, 4784, 4784, 4774, 4776, 4789, 4570, 4570, 4793, 4794, 4794, 4781}
  45. Cache1Attach = {4813, 4822, 4806, 4815, 4824, 4797, 4796, 4823, 4814, 4817, 4826, 4798, 4799, 4825, 4816, 4807, 4804, 4805, 4808, 4809, 4820, 4811, 4810, 4819, 4828, 4800, 4827, 4832, 4812, 4830, 4821, 4829, 4803, 4802, 4801, 4818,  4833, 4831}
  46. Cache2RocketL = {4965, 4965, 4965, 4966, 4966, 4966, 4955, 5123, 5100, 5122, 5124, 5000, 4989, 4982, 4994, 5095, 5095, 5095, 5057, 5057, 5057, 5057, 5058, 5058, 5058, 5058, 5055, 5055, 5055, 4904, 4902, 5094, 4896, 4885}
  47. Cache2Rockets = {4842, 4841, 4836, 4840, 4834, 4843, 4564, 4749, 4726, 4748, 4750, 4609, 4599, 4589,  4603, 4665, 4664, 4663, 4656, 4655, 4654, 4653, 4657, 4660, 4659, 4658, 4650, 4649, 4648, 4507, 4503, 4716, 4500, 4485}
  48. Cache3SifiGuns = {4869, 4870, 5081, 5081, 5091, 5093, 4871, 5069, 5066, 5092, 4887, 4881, 4884, 4892, 4882, 4890, 5078, 4895, 4945, 4879, 4888, 4883, 4893, 4894, 4878, 4889, 4948}
  49. Cache3SifiAmmo = { 4465, 4483, 4692, 4691, 4713, 4715, 4489, 4682, 4693, 4714, 4491, 4484, 4488, 4496, 4486, 4494, 4709, 4499, 4555, 4478, 4492, 4487, 4497, 4498, 4477, 4493, 4558}
  50.  
  51. Guns1 = {
  52.  {id = Cache1Melee[X], count = 1, slot = 23},
  53.  {id = Cache1Misc[A], count = math.random(3), slot = 24},
  54.  {id = Cache1Misc[A1], count = math.random(3), slot = 25},-- note: data is
  55.   {id = Cache1Guns[Y1], count = 1, slot = 0},
  56.   {id = Cache1Guns[Y2], count = 1, slot = 1},
  57.   {id = Cache1Guns[Y3], count = 1, slot = 2},
  58.   {id = Cache1Guns[Y4], count = 1, slot = 3},
  59.   {id = Cache1Guns[Y5], count = 1, slot = 4},
  60.   {id = Cache1Guns[Y6], count = 1, slot = 5},
  61.   {id = Cache1Guns[Y7], count = 1, slot = 6},
  62.   {id = Cache1Guns[Y8], count = 1, slot = 7},
  63.   {id = Cache1Guns[Y9], count = 1, slot = 8},
  64.   {id = Cache1Ammo[Y1], count = math.random(6), slot = 9},
  65.   {id = Cache1Ammo[Y2], count = math.random(6), slot = 10},
  66.   {id = Cache1Ammo[Y3], count = math.random(6), slot = 11},
  67.   {id = Cache1Ammo[Y4], count = math.random(6), slot = 12},
  68.   {id = Cache1Ammo[Y5], count = math.random(6), slot = 13},
  69.   {id = Cache1Ammo[Y6], count = math.random(6), slot = 14},
  70.   {id = Cache1Ammo[Y7], count = math.random(6), slot = 15},
  71.   {id = Cache1Ammo[Y8], count = math.random(6), slot = 16},
  72.   {id = Cache1Ammo[Y9], count = math.random(6), slot = 17},
  73.   {id = Cache1Attach[B2], count = math.random(3), slot = 20},
  74.   {id = 5632, count = 1, slot = 19},
  75.   {id = 5630, count = 1, slot = 18}
  76.  
  77. }
  78. Guns2 = {
  79.  {id = Cache1Melee[X1], count = 1, slot = 23},
  80.  {id = Cache1Misc[A2], count = math.random(3), slot = 24},
  81.  {id = Cache1Misc[A3], count = math.random(3), slot = 25},-- note: data is
  82.   {id = Cache1Guns[Z1], count = 1, slot = 0},
  83.   {id = Cache1Guns[Z2], count = 1, slot = 1},
  84.   {id = Cache1Guns[Z3], count = 1, slot = 2},
  85.   {id = Cache1Guns[Z4], count = 1, slot = 3},
  86.   {id = Cache1Guns[Z5], count = 1, slot = 4},
  87.   {id = Cache1Guns[Z6], count = 1, slot = 5},
  88.   {id = Cache1Guns[Z7], count = 1, slot = 6},
  89.   {id = Cache1Guns[Z8], count = 1, slot = 7},
  90.   {id = Cache1Guns[Z9], count = 1, slot = 8},
  91.   {id = Cache1Ammo[Z1], count = math.random(6), slot = 9},
  92.   {id = Cache1Ammo[Z2], count = math.random(6), slot = 10},
  93.   {id = Cache1Ammo[Z3], count = math.random(6), slot = 11},
  94.   {id = Cache1Ammo[Z4], count = math.random(6), slot = 12},
  95.   {id = Cache1Ammo[Z5], count = math.random(6), slot = 13},
  96.   {id = Cache1Ammo[Z6], count = math.random(6), slot = 14},
  97.   {id = Cache1Ammo[Z7], count = math.random(6), slot = 15},
  98.   {id = Cache1Ammo[Z8], count = math.random(6), slot = 16},
  99.   {id = Cache1Ammo[Z9], count = math.random(6), slot = 17},
  100.   {id = Cache1Attach[B3], count = math.random(3), slot = 18},
  101.   {id = Cache1Attach[B4], count = math.random(3), slot = 19},
  102.   {id = Cache1Attach[B5], count = math.random(3), slot = 20}
  103.  
  104.  
  105. }
  106. Rockets = {
  107.  {id = Cache1Melee[X], count = 1, slot = 23},
  108.  {id = Cache1Misc[A], count = math.random(3), slot = 24},
  109.  {id = Cache1Misc[A1], count = math.random(3), slot = 25},-- note: data is
  110.   {id = Cache2RocketL[Y1], count = 1, slot = 0},
  111.   {id = Cache2RocketL[Y2], count = 1, slot = 1},
  112.   {id = Cache2RocketL[Y3], count = 1, slot = 2},
  113.   {id = Cache2RocketL[Y4], count = 1, slot = 3},
  114.   {id = Cache2RocketL[Y5], count = 1, slot = 4},
  115.   {id = Cache2RocketL[Y6], count = 1, slot = 5},
  116.   {id = Cache2RocketL[Y7], count = 1, slot = 6},
  117.   {id = Cache2RocketL[Y8], count = 1, slot = 7},
  118.   {id = Cache2RocketL[Y9], count = 1, slot = 8},
  119.   {id = Cache2Rockets[Y1], count = math.random(6), slot = 9},
  120.   {id = Cache2Rockets[Y2], count = math.random(6), slot = 10},
  121.   {id = Cache2Rockets[Y3], count = math.random(6), slot = 11},
  122.   {id = Cache2Rockets[Y4], count = math.random(6), slot = 12},
  123.   {id = Cache2Rockets[Y5], count = math.random(6), slot = 13},
  124.   {id = Cache2Rockets[Y6], count = math.random(6), slot = 14},
  125.   {id = Cache2Rockets[Y7], count = math.random(6), slot = 15},
  126.   {id = Cache2Rockets[Y8], count = math.random(6), slot = 16},
  127.   {id = Cache2Rockets[Y9], count = math.random(6), slot = 17},
  128.   {id = Cache1Attach[B2], count = math.random(3), slot = 20},
  129.   {id = 5632, count = 1, slot = 19},
  130.   {id = 5630, count = 1, slot = 18}
  131.  
  132. }
  133. SifiGuns = {
  134.  {id = Cache1Melee[X], count = 1, slot = 23},
  135.  {id = Cache1Misc[A], count = math.random(3), slot = 24},
  136.  {id = Cache1Misc[A1], count = math.random(3), slot = 25},-- note: data is
  137.   {id = Cache3SifiGuns[Y1], count = 1, slot = 0},
  138.   {id = Cache3SifiGuns[Y2], count = 1, slot = 1},
  139.   {id = Cache3SifiGuns[Y3], count = 1, slot = 2},
  140.   {id = Cache3SifiGuns[Y4], count = 1, slot = 3},
  141.   {id = Cache3SifiGuns[Y5], count = 1, slot = 4},
  142.   {id = Cache3SifiGuns[Y6], count = 1, slot = 5},
  143.   {id = Cache3SifiGuns[Y7], count = 1, slot = 6},
  144.   {id = Cache3SifiGuns[Y8], count = 1, slot = 7},
  145.   {id = Cache3SifiGuns[Y9], count = 1, slot = 8},
  146.   {id = Cache3SifiAmmo[Y1], count = math.random(6), slot = 9},
  147.   {id = Cache3SifiAmmo[Y2], count = math.random(6), slot = 10},
  148.   {id = Cache3SifiAmmo[Y3], count = math.random(6), slot = 11},
  149.   {id = Cache3SifiAmmo[Y4], count = math.random(6), slot = 12},
  150.   {id = Cache3SifiAmmo[Y5], count = math.random(6), slot = 13},
  151.   {id = Cache3SifiAmmo[Y6], count = math.random(6), slot = 14},
  152.   {id = Cache3SifiAmmo[Y7], count = math.random(6), slot = 15},
  153.   {id = Cache3SifiAmmo[Y8], count = math.random(6), slot = 16},
  154.   {id = Cache3SifiAmmo[Y9], count = math.random(6), slot = 17},
  155.   {id = Cache1Attach[B2], count = math.random(3), slot = 20},
  156.   {id = 5632, count = 1, slot = 19},
  157.   {id = 5630, count = 1, slot = 18}
  158. }
  159. end
  160. x, y, z = commands.getBlockPosition()
  161. -- Then, summonCrate(xCoords, yCoords, zCoords, table with items)
  162. while true do
  163.     sleep(1)
  164.     Counter = math.random(2)
  165.     Counter2 = math.random(1)
  166.     print("Counter: "..Counter)
  167.     print("Counter2:"..Counter2)
  168.     if  Counter == 0 then
  169.         if  Counter2 == 0 then
  170.             print("Counter2 0")
  171.             RandomNumbers()
  172.             crate.summonCrate(266, 150, 290, Guns1)
  173.             crate.summonCrate(267, 150, 290, Guns2)
  174.         end
  175.         if  Counter2 == 1 then
  176.             print("Counter2 1")
  177.             RandomNumbers()
  178.             crate.summonCrate(283, 150, 199, Guns1)
  179.             crate.summonCrate(282, 150, 199, Guns2)
  180.         end
  181.         print("Counter 0")
  182.         sleep(60*10)
  183.     end
  184. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement