HansCSia320

Dead Winter hack

Apr 30th, 2019
176
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 4.53 KB | None | 0 0
  1. local SpawnGui = Instance.new("ScreenGui")
  2.  
  3. local ItemName = Instance.new("TextBox")
  4.  
  5. local TextButton = Instance.new("TextButton")
  6.  
  7. local Count = Instance.new("TextBox")
  8.  
  9. local TextButton_2 = Instance.new("TextButton")
  10.  
  11. local Hide = Instance.new("TextButton")
  12.  
  13. local Show = Instance.new("TextButton")
  14.  
  15. local SpawnButton = Instance.new("TextButton")
  16.  
  17.  
  18.  
  19. -- Properties
  20.  
  21.  
  22. Hide.Name = "Hide"
  23.  
  24. Hide.Parent = SpawnGui
  25.  
  26. Hide.BackgroundColor3 = Color3.new(1, 1, 1)
  27.  
  28. Hide.Position = UDim2.new(0, 0, 0, 264)
  29.  
  30. Hide.Size = UDim2.new(0, 50, 0, 35)
  31.  
  32. Hide.Font = Enum.Font.SciFi
  33.  
  34. Hide.FontSize = Enum.FontSize.Size10
  35.  
  36. Hide.Text = "Hide <"
  37.  
  38.  
  39.  
  40. Show.Name = "Show"
  41.  
  42. Show.Parent = SpawnGui
  43.  
  44. Show.BackgroundColor3 = Color3.new(1, 1, 1)
  45.  
  46. Show.Position = UDim2.new(0, 0, 0, 264)
  47.  
  48. Show.Size = UDim2.new(0, 50, 0, 35)
  49.  
  50. Show.Visible = false
  51.  
  52. Show.Font = Enum.Font.SciFi
  53.  
  54. Show.FontSize = Enum.FontSize.Size10
  55.  
  56. Show.Text = "Show >"
  57.  
  58.  
  59.  
  60. SpawnGui.Name = "SpawnGui"
  61.  
  62. SpawnGui.Parent = game.CoreGui
  63.  
  64.  
  65.  
  66. ItemName.Name = "ItemName"
  67.  
  68. ItemName.Parent = SpawnGui
  69.  
  70. ItemName.BackgroundColor3 = Color3.new(0.529412, 0.529412, 0.529412)
  71.  
  72. ItemName.Position = UDim2.new(0, 0, 0, 300)
  73.  
  74. ItemName.Size = UDim2.new(0, 200, 0, 50)
  75.  
  76. ItemName.Font = Enum.Font.SciFi
  77.  
  78. ItemName.FontSize = Enum.FontSize.Size14
  79.  
  80. ItemName.Text = "Item"
  81.  
  82.  
  83.  
  84. TextButton.Parent = ItemName
  85.  
  86. TextButton.BackgroundColor3 = Color3.new(1, 0, 0.0156863)
  87.  
  88. TextButton.Position = UDim2.new(0, 200, 0, 0)
  89.  
  90. TextButton.Size = UDim2.new(0, 50, 0, 50)
  91.  
  92. TextButton.Font = Enum.Font.SciFi
  93.  
  94. TextButton.FontSize = Enum.FontSize.Size10
  95.  
  96. TextButton.Text = "Item OK!"
  97.  
  98.  
  99.  
  100. Count.Name = "Count"
  101.  
  102. Count.Parent = SpawnGui
  103.  
  104. Count.BackgroundColor3 = Color3.new(0.529412, 0.529412, 0.529412)
  105.  
  106. Count.Position = UDim2.new(0, 0, 0, 350)
  107.  
  108. Count.Size = UDim2.new(0, 200, 0, 50)
  109.  
  110. Count.Font = Enum.Font.SciFi
  111.  
  112. Count.FontSize = Enum.FontSize.Size14
  113.  
  114. Count.Text = "Stack in item"
  115.  
  116.  
  117.  
  118. TextButton_2.Parent = Count
  119.  
  120. TextButton_2.BackgroundColor3 = Color3.new(1, 0, 0.0156863)
  121.  
  122. TextButton_2.Position = UDim2.new(0, 200, 0, 0)
  123.  
  124. TextButton_2.Size = UDim2.new(0, 50, 0, 50)
  125.  
  126. TextButton_2.Font = Enum.Font.SciFi
  127.  
  128. TextButton_2.FontSize = Enum.FontSize.Size10
  129.  
  130. TextButton_2.Text = "Stack OK!"
  131.  
  132.  
  133.  
  134. SpawnButton.Name = "SpawnButton"
  135.  
  136. SpawnButton.Parent = SpawnGui
  137.  
  138. SpawnButton.BackgroundColor3 = Color3.new(1, 0.666667, 0)
  139.  
  140. SpawnButton.Position = UDim2.new(0, 0, 0, 451)
  141.  
  142. SpawnButton.Size = UDim2.new(0, 250, 0, 40)
  143.  
  144. SpawnButton.Font = Enum.Font.SciFi
  145.  
  146. SpawnButton.FontSize = Enum.FontSize.Size10
  147.  
  148. SpawnButton.Text = "Spawn!"
  149.  
  150. SpawnButton.TextColor3 = Color3.new(0, 0, 0)
  151.  
  152.  
  153.  
  154. lightup = function(button)
  155.  
  156. coroutine.resume(coroutine.create(function()
  157.  
  158. local origincolor = button.BackgroundColor3
  159.  
  160. button.BackgroundColor3 = Color3.new(0, 1, 0)
  161.  
  162. wait(0.1)
  163.  
  164. button.BackgroundColor3 = origincolor
  165.  
  166. end))
  167.  
  168. end
  169.  
  170.  
  171.  
  172. function changename()
  173.  
  174. lightup(TextButton)
  175.  
  176. nameofitem = ItemName.Text
  177.  
  178. end
  179.  
  180. TextButton.MouseButton1Down:connect(changename)
  181.  
  182.  
  183.  
  184. function changeamount()
  185.  
  186. lightup(TextButton_2)
  187.  
  188. Amount = tonumber(Count.Text)
  189.  
  190. end
  191.  
  192. TextButton_2.MouseButton1Down:connect(changeamount)
  193.  
  194.  
  195.  
  196. HideGui = function()
  197.  
  198. lightup(Hide)
  199.  
  200. for _, v in pairs (SpawnGui:GetChildren()) do
  201.  
  202. v.Visible = false
  203.  
  204. end
  205.  
  206. game.Players.LocalPlayer.Character.Humanoid.WalkSpeed = 100
  207. Show.Visible = true
  208.  
  209. end
  210.  
  211. Hide.MouseButton1Down:connect(HideGui)
  212.  
  213.  
  214.  
  215. ShowGui = function()
  216.  
  217. lightup(Show)
  218.  
  219. for _, v in pairs (SpawnGui:GetChildren()) do
  220.  
  221. v.Visible = true
  222.  
  223. end
  224.  
  225. Show.Visible = false
  226.  
  227. end
  228.  
  229. Show.MouseButton1Down:connect(ShowGui)
  230.  
  231.  
  232.  
  233. local player = game.Players.LocalPlayer
  234.  
  235. local user = player.Character;
  236.  
  237. local cam = workspace.CurrentCamera;
  238.  
  239.  
  240.  
  241. function spawnitem()
  242.  
  243. lightup(SpawnButton)
  244.  
  245. if Amount and nameofitem then
  246.  
  247. for i = 1, Amount do
  248.  
  249. local player = game.Players.LocalPlayer
  250.  
  251. local user = player.Character;
  252.  
  253. local cam = workspace.CurrentCamera;
  254.  
  255. local hit, position =
  256. workspace:FindPartOnRayWithIgnoreList(Ray.new((user.Torso.CFrame*CFrame.new(0,
  257. 0, -5)).p, Vector3.new(0, -60, 0)), {cam, workspace.Terrain});
  258.  
  259. local area = CFrame.new(position+Vector3.new(0, 3, 0))*CFrame.Angles(0, math.rad(math.random(0, 359)), 0);
  260.  
  261. local origin = game.Players.LocalPlayer.Character.Torso.CFrame;
  262.  
  263. local cframe = area*origin:toObjectSpace(game.Players.LocalPlayer.Character.Torso.CFrame);
  264.  
  265. game.Workspace.resources.events.createItemInWorld:FireServer(10, tostring(nameofitem), cframe)
  266.  
  267. end
  268.  
  269. end
  270.  
  271. end
  272.  
  273.  
  274.  
  275. SpawnButton.MouseButton1Down:connect(spawnitem)
Add Comment
Please, Sign In to add comment