Advertisement
Upscalefanatic3

*UPDATED* Fray Unlock All, Crates, and Credits

Oct 25th, 2018
336
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.09 KB | None | 0 0
  1. -- run this script and press f9 to open the console to see the status
  2.  
  3. -- if you get kicked, change the eventDelay variable at the top to .5 or so, but this will make it take longer
  4.  
  5. -- what this does by default:
  6. -- 50 legendary crates,
  7. -- 5000 credits
  8. -- all weapons unlocked
  9. -- all streaks unlocked
  10. -- all camos unlocked
  11.  
  12. -- how to use:
  13. -- join the main menu, run this script, and don't touch anything other than f9 until it's done
  14.  
  15. -- updated 10/22/18
  16. -- 8:59 pm
  17.  
  18.  
  19.  
  20.  
  21.  
  22.  
  23.  
  24. local ReplicatedStorage = game:GetService('ReplicatedStorage')
  25. local Players = game:GetService('Players')
  26.  
  27. local player = Players.LocalPlayer
  28. local events = {}
  29. for i, event in next, ReplicatedStorage.Events:GetChildren() do
  30. events[event.Name] = event
  31. end
  32.  
  33. local maxCredits = 500
  34. local maxCrates = 1
  35. local eventDelay = .4 -- change this to .5 or so if you're missing items at the price of speed
  36. local calls = 0
  37.  
  38. local initialize
  39.  
  40. local function getInitialize()
  41. if getnilinstances then
  42. for i, v in next, getnilinstances() do
  43. if v:FindFirstChild('ServerTime') then
  44. return require(v:Clone()).Initialize
  45. end
  46. end
  47. else
  48. return function()
  49. local f = Workspace.Terrain:FindFirstChild('BrightnessCoefficient')
  50. if f then
  51. return math.floor(100000000 * (f.Value - 55) ^ .1943)
  52. end
  53. end
  54. end
  55.  
  56. error('Failed to get Initialize')
  57. end
  58.  
  59. local function getKey()
  60. if not initialize then
  61. initialize = getInitialize()
  62. end
  63.  
  64. calls = calls + 1
  65. return initialize(calls)
  66. end
  67.  
  68. local function giveCredits(amount)
  69. events.ChangeData:FireServer(player.Data.Credits, player.Data.Credits.Value + amount, getKey(), amount + 1)
  70. wait(eventDelay)
  71. end
  72.  
  73. local function giveCrate(_type)
  74. local crate = 'Free' .. _type
  75. events.ChangeData:FireServer(player.Data[crate], player.Data[crate].Value + 1, getKey(), 2)
  76. wait(eventDelay)
  77. end
  78.  
  79. local function earlyUnlock(name)
  80. events.ChangeData:FireServer(player.Data.EarlyUnlocks, player.Data.EarlyUnlocks.Value .. name, getKey())
  81. wait(eventDelay)
  82. end
  83.  
  84. local function unlockCamo(weapon, name)
  85. events.ChangeData:FireServer(player.WeaponData[weapon].Items, player.WeaponData[weapon].Items.Value .. name, getKey())
  86. wait(eventDelay)
  87. end
  88.  
  89. local perks = {
  90. 'Munition Expert',
  91. 'Nickle-back', -- doesn't save, probably a game bug
  92. 'Overclock',
  93. 'Focused',
  94. 'Longblade',
  95. 'Extra Security',
  96. 'Starved Arms',
  97. 'False Security',
  98. 'Tagged',
  99. 'Bottomless Pockets',
  100. 'Depreciation',
  101. 'Good Credit',
  102. 'Armed & Dangerous',
  103. 'Hollow Bones',
  104. 'Time Stopper',
  105. 'Classified',
  106. 'Armored',
  107. 'Shadow',
  108. }
  109.  
  110. local streaks = {
  111. 'UAV',
  112. 'CounterUAV',
  113. 'Advanced UAV',
  114. 'Anti Air',
  115. 'Carpet Bomber',
  116. 'Attack Drone',
  117. 'A10',
  118. 'AGV',
  119. 'Orbital Strike'
  120. }
  121.  
  122. --[[
  123. by default, this script does the following:
  124. 50 legendary crates,
  125. 5000 credits
  126. all weapons unlocked
  127. all streaks unlocked
  128. all camos unlocked
  129. ]]
  130.  
  131. -- crates
  132. local amount = 50
  133. local done = 0
  134. for i = 1, amount / maxCrates do
  135. giveCrate('Legendary')
  136. done = done + maxCrates
  137. print('Crates ' .. done .. '/' .. amount)
  138. end
  139. print('Gave ' .. amount .. ' Crates')
  140.  
  141. -- credits
  142. amount = 5000
  143. done = 0
  144. for i = 1, amount / maxCredits do
  145. giveCredits(maxCredits)
  146. done = done + maxCredits
  147. print('Credits ' .. done .. '/' .. amount)
  148. end
  149. print('Gave ' .. amount .. ' Credits')
  150.  
  151. local weapons = {unpack(ReplicatedStorage.Weapons:GetChildren())}
  152. for i, weapon in next, weapons do
  153. earlyUnlock(weapon.Name)
  154. print('Weapon (' .. i .. '/' .. #weapons .. ')')
  155. end
  156. print('Unlocked Weapons')
  157.  
  158. -- streaks
  159. for i, streak in next, streaks do
  160. earlyUnlock(streak)
  161. print('Streak (' .. i .. '/' .. #streaks .. ')')
  162. end
  163. print('Unlocked Streaks')
  164.  
  165. -- perks
  166. for i, perk in next, perks do
  167. earlyUnlock(perk)
  168. print('Perk (' .. i .. '/' .. #perks .. ')')
  169. end
  170. print('Unlocked Perks')
  171.  
  172. -- camos
  173. local camos = {unpack(ReplicatedStorage.Camos:GetChildren())}
  174. local weapons = {unpack(player.WeaponData:GetChildren())}
  175. for i, camo in next, camos do
  176. for z, weapon in next, weapons do
  177. unlockCamo(weapon.Name, camo.Name)
  178. end
  179. print('Camo (' .. i .. '/' .. #camos .. ')')
  180. end
  181. print('Unlocked Camos')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement