Advertisement
Guest User

Roblox Script!!!!!!!

a guest
May 6th, 2019
597
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 22.38 KB | None | 0 0
  1. --[[
  2. ~ Description ~
  3.  
  4. This is a pretty powerful script I've made, you can edit some stuff at the top here (like the wall size/shape)
  5. along with the distance of the kill aura.
  6.  
  7. This was a really fun script to make all in all so :D cheers
  8. --------------------------------
  9. ~ Game ~
  10.  
  11. https://www.roblox.com/games/3056526277/Build-Survive#!/game-instances
  12. --------------------------------
  13. ~ Credit ~
  14.  
  15. Gui - brianops1
  16.  
  17. Scripter(s) - briansop1
  18. --]]
  19.  
  20. x = -252
  21. y = -8 --starting floor is -8
  22. z = 48 --Change this (by increments of 4) to change where the location of the wall is
  23. amount = 10
  24. WT = .01
  25.  
  26. _G.AuraDist = 75
  27.  
  28. KPLocation = 2 -- 1 is the closest to the mobs spawn (for loot to still drop), 4 is the farthest (closest to building area)
  29.  
  30. _G.KEY = "LeftAlt" -- for the tp to mouse keybind
  31. _G.KEY1 = "H" -- for the Noclip keybind
  32.  
  33. function define()
  34. plr = game:GetService('Players').LocalPlayer
  35. Root = plr.Character.HumanoidRootPart
  36. UIS = game:GetService("UserInputService")
  37. mouse = plr:GetMouse()
  38. end
  39. print('loading')
  40. repeat
  41. wait()
  42. until pcall(define)
  43. local ScreenGui = Instance.new("ScreenGui")
  44. local MainFrame = Instance.new("Frame")
  45. local PreBuilt = Instance.new("Frame")
  46. local EB1 = Instance.new("TextButton")
  47. local Toplabel = Instance.new("TextLabel")
  48. local EB2 = Instance.new("TextButton")
  49. local EB3 = Instance.new("TextButton")
  50. local EB4 = Instance.new("TextButton")
  51. local EB5 = Instance.new("TextButton")
  52. local EB6 = Instance.new("TextButton")
  53. local Bottomlabel = Instance.new("TextLabel")
  54. local Game = Instance.new("TextLabel")
  55. local Minimize = Instance.new("TextButton")
  56. local Close = Instance.new("TextButton")
  57. local Credits = Instance.new("TextLabel")
  58. local B1 = Instance.new("TextButton")
  59. local B2 = Instance.new("TextButton")
  60. local B5 = Instance.new("TextButton")
  61. local B8 = Instance.new("TextButton")
  62. local B6 = Instance.new("TextButton")
  63. local B4 = Instance.new("TextButton")
  64. local B7 = Instance.new("TextButton")
  65. local B3 = Instance.new("TextButton")
  66. local BuiltInButton = Instance.new("TextButton")
  67. local Background = Instance.new("ImageLabel")
  68. ---------------------Gui Variables----------------------
  69. ScreenGui.Parent = game.CoreGui
  70. MainFrame.Name = "MainFrame"
  71. MainFrame.Parent = ScreenGui
  72. MainFrame.BackgroundColor3 = Color3.new(1, 1, 1)
  73. MainFrame.BorderColor3 = Color3.new(1, 0.835294, 0.172549)
  74. MainFrame.BorderSizePixel = 2
  75. MainFrame.Position = UDim2.new(0, 270, 0, 101)
  76. MainFrame.Size = UDim2.new(0, 278, 0, 279)
  77. MainFrame.Selectable = true
  78. MainFrame.Active = true
  79. MainFrame.Draggable = true
  80. PreBuilt.Name = "PreBuilt"
  81. PreBuilt.Parent = MainFrame
  82. PreBuilt.BackgroundColor3 = Color3.new(0.972549, 0.764706, 0.129412)
  83. PreBuilt.BorderSizePixel = 0
  84. PreBuilt.Position = UDim2.new(0, 287, 0, 17)
  85. PreBuilt.Size = UDim2.new(0, 186, 0, 246)
  86. PreBuilt.Visible = false
  87. EB1.Name = "EB1"
  88. EB1.Parent = PreBuilt
  89. EB1.BackgroundColor3 = Color3.new(1, 1, 1)
  90. EB1.BackgroundTransparency = 0.30000001192093
  91. EB1.BorderSizePixel = 0
  92. EB1.Position = UDim2.new(0, 0, 0.117886186, 0)
  93. EB1.Size = UDim2.new(0, 186, 0, 25)
  94. EB1.Font = Enum.Font.SourceSans
  95. EB1.Text = ""
  96. EB1.TextColor3 = Color3.new(0, 0, 0)
  97. EB1.TextSize = 13
  98. Toplabel.Name = "Toplabel"
  99. Toplabel.Parent = PreBuilt
  100. Toplabel.BackgroundColor3 = Color3.new(1, 1, 1)
  101. Toplabel.BackgroundTransparency = 0.20000000298023
  102. Toplabel.BorderSizePixel = 0
  103. Toplabel.Position = UDim2.new(0, 0, -0.008130081, 0)
  104. Toplabel.Size = UDim2.new(0, 186, 0, 25)
  105. Toplabel.Font = Enum.Font.SourceSans
  106. Toplabel.Text = "Built In Scripts"
  107. Toplabel.TextColor3 = Color3.new(0, 0, 0)
  108. Toplabel.TextSize = 14
  109. Toplabel.TextWrapped = true
  110. EB2.Name = "EB2"
  111. EB2.Parent = PreBuilt
  112. EB2.BackgroundColor3 = Color3.new(1, 1, 1)
  113. EB2.BackgroundTransparency = 0.30000001192093
  114. EB2.BorderSizePixel = 0
  115. EB2.Position = UDim2.new(0, 0, 0.243902445, 0)
  116. EB2.Size = UDim2.new(0, 186, 0, 25)
  117. EB2.Font = Enum.Font.SourceSans
  118. EB2.Text = ""
  119. EB2.TextColor3 = Color3.new(0, 0, 0)
  120. EB2.TextSize = 13
  121. EB3.Name = "EB3"
  122. EB3.Parent = PreBuilt
  123. EB3.BackgroundColor3 = Color3.new(1, 1, 1)
  124. EB3.BackgroundTransparency = 0.30000001192093
  125. EB3.BorderSizePixel = 0
  126. EB3.Position = UDim2.new(0, 0, 0, 91)
  127. EB3.Size = UDim2.new(0, 186, 0, 25)
  128. EB3.Font = Enum.Font.SourceSans
  129. EB3.Text = ""
  130. EB3.TextColor3 = Color3.new(0, 0, 0)
  131. EB3.TextSize = 13
  132. EB4.Name = "EB4"
  133. EB4.Parent = PreBuilt
  134. EB4.BackgroundColor3 = Color3.new(1, 1, 1)
  135. EB4.BackgroundTransparency = 0.30000001192093
  136. EB4.BorderSizePixel = 0
  137. EB4.Position = UDim2.new(0, 0, 0.495934963, 0)
  138. EB4.Size = UDim2.new(0, 186, 0, 25)
  139. EB4.Font = Enum.Font.SourceSans
  140. EB4.Text = ""
  141. EB4.TextColor3 = Color3.new(0, 0, 0)
  142. EB4.TextSize = 13
  143. EB5.Name = "EB5"
  144. EB5.Parent = PreBuilt
  145. EB5.BackgroundColor3 = Color3.new(1, 1, 1)
  146. EB5.BackgroundTransparency = 0.30000001192093
  147. EB5.BorderSizePixel = 0
  148. EB5.Position = UDim2.new(0, 0, 0, 153)
  149. EB5.Size = UDim2.new(0, 186, 0, 25)
  150. EB5.Font = Enum.Font.SourceSans
  151. EB5.Text = ""
  152. EB5.TextColor3 = Color3.new(0, 0, 0)
  153. EB5.TextSize = 13
  154. EB6.Name = "EB6"
  155. EB6.Parent = PreBuilt
  156. EB6.BackgroundColor3 = Color3.new(1, 1, 1)
  157. EB6.BackgroundTransparency = 0.30000001192093
  158. EB6.BorderSizePixel = 0
  159. EB6.Position = UDim2.new(0, 0, 0.747967541, 0)
  160. EB6.Size = UDim2.new(0, 186, 0, 25)
  161. EB6.Font = Enum.Font.SourceSans
  162. EB6.Text = ""
  163. EB6.TextColor3 = Color3.new(0, 0, 0)
  164. EB6.TextSize = 13
  165. Bottomlabel.Name = "Bottomlabel"
  166. Bottomlabel.Parent = PreBuilt
  167. Bottomlabel.BackgroundColor3 = Color3.new(1, 1, 1)
  168. Bottomlabel.BackgroundTransparency = 0.20000000298023
  169. Bottomlabel.BorderSizePixel = 0
  170. Bottomlabel.Position = UDim2.new(0, 0, 0.898373961, 0)
  171. Bottomlabel.Size = UDim2.new(0, 186, 0, 25)
  172. Bottomlabel.Font = Enum.Font.SourceSans
  173. Bottomlabel.Text = "Good Scripts to have eh?"
  174. Bottomlabel.TextColor3 = Color3.new(0, 0, 0)
  175. Bottomlabel.TextSize = 13
  176. Game.Name = "Game"
  177. Game.Parent = MainFrame
  178. Game.BackgroundColor3 = Color3.new(1, 1, 1)
  179. Game.BackgroundTransparency = 0.20000000298023
  180. Game.BorderColor3 = Color3.new(1, 1, 1)
  181. Game.BorderSizePixel = 0
  182. Game.Position = UDim2.new(0, 0,0, -2)
  183. Game.Size = UDim2.new(0, 227, 0, 25)
  184. Game.ZIndex = 2
  185. Game.Font = Enum.Font.SourceSans
  186. Game.Text = "Game Name Is Supposed to Be Here"
  187. Game.TextColor3 = Color3.new(0, 0, 0)
  188. Game.TextSize = 13
  189. Game.TextWrapped = true
  190. Minimize.Name = "Minimize"
  191. Minimize.Parent = MainFrame
  192. Minimize.BackgroundColor3 = Color3.new(1, 1, 1)
  193. Minimize.BackgroundTransparency = 0.20000000298023
  194. Minimize.BorderSizePixel = 0
  195. Minimize.Position = UDim2.new(0, 227,0, -2)
  196. Minimize.Size = UDim2.new(0, 25, 0, 25)
  197. Minimize.ZIndex = 2
  198. Minimize.Font = Enum.Font.SourceSans
  199. Minimize.Text = "-"
  200. Minimize.TextColor3 = Color3.new(0, 0, 0)
  201. Minimize.TextSize = 24
  202. Close.Name = "Close"
  203. Close.Parent = MainFrame
  204. Close.BackgroundColor3 = Color3.new(1, 1, 1)
  205. Close.BackgroundTransparency = 0.20000000298023
  206. Close.BorderSizePixel = 0
  207. Close.Position = UDim2.new(0, 251, 0, -2)
  208. Close.Size = UDim2.new(0, 28, 0, 25)
  209. Close.ZIndex = 2
  210. Close.Font = Enum.Font.SourceSans
  211. Close.Text = "x"
  212. Close.TextColor3 = Color3.new(0, 0, 0)
  213. Close.TextSize = 16
  214. Credits.Name = "Credits"
  215. Credits.Parent = MainFrame
  216. Credits.BackgroundColor3 = Color3.new(1, 1, 1)
  217. Credits.BackgroundTransparency = 0.20000000298023
  218. Credits.BorderColor3 = Color3.new(1, 1, 1)
  219. Credits.BorderSizePixel = 0
  220. Credits.Position = UDim2.new(-0.00359712238, 0, 0.9048931, 0)
  221. Credits.Size = UDim2.new(0, 278, 0, 28)
  222. Credits.ZIndex = 2
  223. Credits.Font = Enum.Font.SourceSans
  224. Credits.Text = "Gui ~ brianops1 | Scripter(s) ~ "
  225. Credits.TextColor3 = Color3.new(0, 0, 0)
  226. Credits.TextSize = 13
  227. Credits.TextWrapped = true
  228. B1.Name = "B1"
  229. B1.Parent = MainFrame
  230. B1.BackgroundColor3 = Color3.new(1, 1, 1)
  231. B1.BackgroundTransparency = 0.20000000298023
  232. B1.BorderColor3 = Color3.new(1, 1, 1)
  233. B1.Position = UDim2.new(0.0242086351, 0, 0.218306571, 0)
  234. B1.Size = UDim2.new(0, 125, 0, 40)
  235. B1.ZIndex = 2
  236. B1.Font = Enum.Font.SourceSans
  237. B1.Text = ""
  238. B1.TextColor3 = Color3.new(0, 0, 0)
  239. B1.TextSize = 13
  240. B1.TextWrapped = true
  241. B2.Name = "B2"
  242. B2.Parent = MainFrame
  243. B2.BackgroundColor3 = Color3.new(1, 1, 1)
  244. B2.BackgroundTransparency = 0.20000000298023
  245. B2.BorderColor3 = Color3.new(1, 1, 1)
  246. B2.Position = UDim2.new(0, 144, 0, 60)
  247. B2.Size = UDim2.new(0, 125, 0, 41)
  248. B2.ZIndex = 2
  249. B2.Font = Enum.Font.SourceSans
  250. B2.Text = ""
  251. B2.TextColor3 = Color3.new(0, 0, 0)
  252. B2.TextSize = 13
  253. B2.TextWrapped = true
  254. B5.Name = "B5"
  255. B5.Parent = MainFrame
  256. B5.BackgroundColor3 = Color3.new(1, 1, 1)
  257. B5.BackgroundTransparency = 0.20000000298023
  258. B5.BorderColor3 = Color3.new(1, 1, 1)
  259. B5.Position = UDim2.new(0.0251798555, 0, 0.559432089, 0)
  260. B5.Size = UDim2.new(0, 125, 0, 40)
  261. B5.ZIndex = 2
  262. B5.Font = Enum.Font.SourceSans
  263. B5.Text = ""
  264. B5.TextColor3 = Color3.new(0, 0, 0)
  265. B5.TextSize = 13
  266. B5.TextWrapped = true
  267. B8.Name = "B8"
  268. B8.Parent = MainFrame
  269. B8.BackgroundColor3 = Color3.new(1, 1, 1)
  270. B8.BackgroundTransparency = 0.20000000298023
  271. B8.BorderColor3 = Color3.new(1, 1, 1)
  272. B8.Position = UDim2.new(0, 144, 0, 204)
  273. B8.Size = UDim2.new(0, 125, 0, 40)
  274. B8.ZIndex = 2
  275. B8.Font = Enum.Font.SourceSans
  276. B8.Text = ""
  277. B8.TextColor3 = Color3.new(0, 0, 0)
  278. B8.TextSize = 13
  279. B8.TextWrapped = true
  280. B6.Name = "B6"
  281. B6.Parent = MainFrame
  282. B6.BackgroundColor3 = Color3.new(1, 1, 1)
  283. B6.BackgroundTransparency = 0.20000000298023
  284. B6.BorderColor3 = Color3.new(1, 1, 1)
  285. B6.Position = UDim2.new(0.517985642, 0, 0.557863712, 0)
  286. B6.Size = UDim2.new(0, 125, 0, 40)
  287. B6.ZIndex = 2
  288. B6.Font = Enum.Font.SourceSans
  289. B6.Text = ""
  290. B6.TextColor3 = Color3.new(0, 0, 0)
  291. B6.TextSize = 13
  292. B6.TextWrapped = true
  293. B4.Name = "B4"
  294. B4.Parent = MainFrame
  295. B4.BackgroundColor3 = Color3.new(1, 1, 1)
  296. B4.BackgroundTransparency = 0.20000000298023
  297. B4.BorderColor3 = Color3.new(1, 1, 1)
  298. B4.Position = UDim2.new(0, 144, 0, 109)
  299. B4.Size = UDim2.new(0, 125, 0, 40)
  300. B4.ZIndex = 2
  301. B4.Font = Enum.Font.SourceSans
  302. B4.Text = ""
  303. B4.TextColor3 = Color3.new(0, 0, 0)
  304. B4.TextSize = 13
  305. B4.TextWrapped = true
  306. B7.Name = "B7"
  307. B7.Parent = MainFrame
  308. B7.BackgroundColor3 = Color3.new(1, 1, 1)
  309. B7.BackgroundTransparency = 0.20000000298023
  310. B7.BorderColor3 = Color3.new(1, 1, 1)
  311. B7.Position = UDim2.new(0.0251798555, 0, 0.731607914, 0)
  312. B7.Size = UDim2.new(0, 125, 0, 40)
  313. B7.ZIndex = 2
  314. B7.Font = Enum.Font.SourceSans
  315. B7.Text = ""
  316. B7.TextColor3 = Color3.new(0, 0, 0)
  317. B7.TextSize = 13
  318. B7.TextWrapped = true
  319. B3.Name = "B3"
  320. B3.Parent = MainFrame
  321. B3.BackgroundColor3 = Color3.new(1, 1, 1)
  322. B3.BackgroundTransparency = 0.20000000298023
  323. B3.BorderColor3 = Color3.new(1, 1, 1)
  324. B3.Position = UDim2.new(0.0251798555, 0, 0.392196536, 0)
  325. B3.Size = UDim2.new(0, 125, 0, 40)
  326. B3.ZIndex = 2
  327. B3.Font = Enum.Font.SourceSans
  328. B3.Text = ""
  329. B3.TextColor3 = Color3.new(0, 0, 0)
  330. B3.TextSize = 13
  331. B3.TextWrapped = true
  332. BuiltInButton.Name = "BuiltInButton"
  333. BuiltInButton.Parent = MainFrame
  334. BuiltInButton.BackgroundColor3 = Color3.new(1, 1, 1)
  335. BuiltInButton.BackgroundTransparency = 0.20000000298023
  336. BuiltInButton.BorderSizePixel = 0
  337. BuiltInButton.Position = UDim2.new(0.0242086723, 0, 0.112921163, 0)
  338. BuiltInButton.Size = UDim2.new(0, 262, 0, 22)
  339. BuiltInButton.ZIndex = 2
  340. BuiltInButton.Font = Enum.Font.SourceSans
  341. BuiltInButton.Text = "Toggle Built-In Gui Scripts"
  342. BuiltInButton.TextColor3 = Color3.new(0, 0, 0)
  343. BuiltInButton.TextSize = 13
  344. BuiltInButton.TextWrapped = true
  345. Background.Name = "Background"
  346. Background.Parent = MainFrame
  347. Background.BackgroundColor3 = Color3.new(1, 1, 1)
  348. Background.BorderSizePixel = 0
  349. Background.LayoutOrder = 1
  350. Background.Size = UDim2.new(0, 277, 0, 281)
  351. Background.Image = "rbxassetid://325122566"
  352. B1.BorderSizePixel = 0
  353. B2.BorderSizePixel = 0
  354. B3.BorderSizePixel = 0
  355. B4.BorderSizePixel = 0
  356. B5.BorderSizePixel = 0
  357. B6.BorderSizePixel = 0
  358. B7.BorderSizePixel = 0
  359. B8.BorderSizePixel = 0
  360. _G.noclip = false
  361. ------------------PreBuilt Scripts-----------------------
  362. EB1.Text = "Dex"
  363. EB2.Text = "R2S"
  364. EB3.Text = "Noclip (Default H)"
  365. EB4.Text = "Tp to mouse (Default LeftAlt)"
  366. EB5.Text = "Print/Copy Vector3 position"
  367. EB6.Text = "Baseplate (click again to tp back)"
  368.  
  369. EB1.MouseButton1Click:connect(function()
  370. loadstring(game:GetObjects('rbxassetid://2180084478')[1].Source)()
  371. end)
  372. EB2.MouseButton1Click:connect(function()
  373. loadstring(game:HttpGet(('https://pastebin.com/raw/c12tidMB'),true))()
  374. end)
  375. EB3.MouseButton1Click:connect(function()
  376. UIS.InputBegan:connect(function(Input)
  377. plr = game:GetService('Players').LocalPlayer
  378. UIS = game:GetService("UserInputService")
  379. mouse = plr:GetMouse()
  380. local KeyCode = Input.KeyCode
  381. if KeyCode == Enum.KeyCode[_G.KEY1] and _G.noclip == false then
  382. _G.noclip = true
  383. while _G.noclip do
  384. plr.Character.Humanoid:ChangeState(11)
  385. game:GetService('RunService').Stepped:wait()
  386. end
  387. elseif KeyCode == Enum.KeyCode[_G.KEY1] and _G.noclip then
  388. _G.noclip = false
  389. end
  390. end)
  391. end)
  392. EB4.MouseButton1Click:connect(function()
  393. UIS.InputBegan:connect(function(Input)
  394. plr = game:GetService('Players').LocalPlayer
  395. UIS = game:GetService("UserInputService")
  396. mouse = plr:GetMouse()
  397. local KeyCode = Input.KeyCode
  398. if KeyCode == Enum.KeyCode[_G.KEY] then
  399. local hum = plr.Character.HumanoidRootPart
  400. if mouse.Target then
  401. hum.CFrame = CFrame.new(mouse.Hit.x, mouse.Hit.y + 4, mouse.Hit.z)
  402. end
  403. end
  404. end)
  405. end)
  406. EB5.MouseButton1Click:connect(function()
  407. x = loc(Root.CFrame.x)
  408. y = loc(Root.CFrame.y)
  409. z = loc(Root.CFrame.z)
  410. print('-----------------')
  411. print('Your x value is '.. x)
  412. print('Your y value is '.. y)
  413. print('Your z value is '.. z)
  414. pcall(copy,x,y,z)
  415. end)
  416. EB6.MouseButton1Click:connect(function()
  417. local check = game.Workspace:FindFirstChild("BRIAN'S PLATFORM")
  418. if check then
  419. Root.CFrame = _G.StartingPosition
  420. check:Destroy()
  421. else
  422. _G.StartingPosition = Root.CFrame
  423. local P = Instance.new("Part", workspace)
  424. P.Anchored = true
  425. P.CFrame = Root.CFrame * CFrame.new(0, 5500, 0)
  426. P.Name = "BRIAN'S PLATFORM"
  427. P.Size = Vector3.new(80, 1, 80)
  428. Root.CFrame = P.CFrame * CFrame.new(0,5,0)
  429. end
  430. end)
  431.  
  432. ---------------------Functions---------------------------
  433. function VarOff()
  434. _G.on1 = 0
  435. _G.on2 = 0
  436. _G.on3 = 0
  437. _G.on4 = 0
  438. _G.on5 = 0
  439. _G.on6 = 0
  440. _G.on7 = 0
  441. _G.on8 = 0
  442. end
  443. function loc(cframe)
  444. local location = string.find(cframe, ".", 1, true)
  445. if location == nil then
  446. return cframe
  447. end
  448. return string.sub(cframe, 1, location + 1)
  449. end
  450. function copy(x,y,z)
  451. setclipboard(x .. ", " .. y .. ", " .. z)
  452. end
  453. VarOff()
  454. m = 0
  455. Minimize.MouseButton1Click:connect(function()
  456. if m == 0 then
  457. m = 1
  458. opennn = PreBuilt.Visible
  459. B1.Visible = false
  460. B2.Visible = false
  461. B3.Visible = false
  462. B4.Visible = false
  463. B5.Visible = false
  464. B6.Visible = false
  465. B7.Visible = false
  466. B8.Visible = false
  467. BuiltInButton.Visible = false
  468. Credits.Visible = false
  469. PreBuilt.Visible = false
  470. Background.Size = UDim2.new(0,278,0,25)
  471. MainFrame.Size = UDim2.new(0,278,0,25)
  472. else
  473. m = 0
  474. B1.Visible = true
  475. B2.Visible = true
  476. B3.Visible = true
  477. B4.Visible = true
  478. B5.Visible = true
  479. B6.Visible = true
  480. B7.Visible = true
  481. B8.Visible = true
  482. BuiltInButton.Visible = true
  483. Credits.Visible = true
  484. PreBuilt.Visible = opennn
  485. Background.Size = UDim2.new(0,278,0,281)
  486. MainFrame.Size = UDim2.new(0,278,0,279)
  487. end
  488. end)
  489. Close.MouseButton1Click:connect(function()
  490. VarOff()
  491. ScreenGui:Destroy()
  492. end)
  493. builtin = 0
  494. BuiltInButton.MouseButton1Click:connect(function()
  495. if builtin == 0 then
  496. builtin = 1
  497. PreBuilt.Visible = true
  498. else
  499. builtin = 0
  500. PreBuilt.Visible = false
  501. end
  502. end)
  503. function ON(button)
  504. if button.Name == "B1" then
  505. _G.on1 = 1
  506. elseif button.Name == "B2" then
  507. _G.on2 = 1
  508. elseif button.Name == "B3" then
  509. _G.on3 = 1
  510. elseif button.Name == "B4" then
  511. _G.on4 = 1
  512. elseif button.Name == "B5" then
  513. _G.on5 = 1
  514. elseif button.Name == "B6" then
  515. _G.on6 = 1
  516. elseif button.Name == "B7" then
  517. _G.on7 = 1
  518. elseif button.Name == "B8" then
  519. _G.on8 = 1
  520. end
  521. button.BorderSizePixel = 2
  522. button.BorderColor3 = Color3.fromRGB(0, 0, 0)
  523. end
  524. function OFF(button)
  525. if button.Name == "B1" then
  526. _G.on1 = 0
  527. elseif button.Name == "B2" then
  528. _G.on2 = 0
  529. elseif button.Name == "B3" then
  530. _G.on3 = 0
  531. elseif button.Name == "B4" then
  532. _G.on4 = 0
  533. elseif button.Name == "B5" then
  534. _G.on5 = 0
  535. elseif button.Name == "B6" then
  536. _G.on6 = 0
  537. elseif button.Name == "B7" then
  538. _G.on7 = 0
  539. elseif button.Name == "B8" then
  540. _G.on8 = 0
  541. end
  542. button.BorderSizePixel = 0
  543. button.BorderColor3 = Color3.fromRGB(255, 255, 255)
  544. end
  545. function DMG(amt,obj)
  546. local A_1 =
  547. {
  548. [1] =
  549. {
  550. [1] = obj,
  551. [2] = amt
  552. }
  553. }
  554. local Event = game:GetService("Workspace")["__REMOTES"].Game["Mob Do Damage"]
  555. Event:FireServer(A_1)
  556. end
  557. function isin(obj,tbl)
  558. for a = 1,#tbl do
  559. if obj == tbl[a] then
  560. return true
  561. end
  562. end
  563. return false
  564. end
  565. function place(M,x,y,z)
  566. local A_1 = CFrame.new(x, y, z, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  567. local A_2 = M
  568. local A_3 = game:GetService("Workspace"):FindFirstChildOfClass("Part",true)
  569. local A_4 = CFrame.new(x, y, z, 1, 0, 0, 0, 1, 0, 0, 0, 1)
  570. local Event = game:GetService("Workspace")["__REMOTES"].Game["Place Block"]
  571. Event:FireServer(A_1, A_2, A_3, A_4)
  572. end
  573. ---------------------Main Code---------------------------
  574.  
  575. Game.Text = "Build and survive" -- Game name here
  576.  
  577. Credits.Text = Credits.Text .. "brianops1" --Scripter(s) name(s) here
  578.  
  579.  
  580. B1.Text = "Kill All Monsters (and pickup loot)" --Script Names go here
  581. B2.Text = "Kill Aura and autopickup loot"
  582. B3.Text = "Kill Part"
  583. B4.Text = "Wood Wall"
  584. B5.Text = "Brick Wall"
  585. B6.Text = "Metal Wall"
  586. B7.Text = ""
  587. B8.Text = ""
  588.  
  589.  
  590. B1.MouseButton1Click:connect(function()
  591. if _G.on1 == 1 then
  592. OFF(B1)
  593. else
  594. ON(B1)
  595. game:GetService('RunService').Stepped:wait()
  596. for i,v in pairs(game:GetService("Workspace")["__THINGS"].Monsters:GetChildren()) do
  597. if v and v.ClassName == "Model" then
  598. if v.Name == "RougeBot" then
  599. DMG(85,v)
  600. elseif v.Name == "Robot" then
  601. DMG(80,v)
  602. elseif v.Name == "Zombie" then
  603. DMG(100,v)
  604. elseif v.Name == "Skeleton" then
  605. DMG(80,v)
  606. elseif v.Name == "Tank" then
  607. DMG(675,v)
  608. else
  609. DMG(100,v)
  610. end
  611. end
  612. end
  613. wait(.5)
  614. for i,v in pairs(game:GetService("Workspace")["__DEBRIS"]:GetChildren()) do
  615. local ID = v:FindFirstChild("UID")
  616. if ID then
  617. local A_1 =
  618. {
  619. [1] = ID.Value
  620. }
  621. local Event = game:GetService("Workspace")["__REMOTES"].Game["Redeem Drop"]
  622. Event:FireServer(A_1)
  623. end
  624. end
  625. OFF(B1)
  626. end
  627. end)
  628.  
  629. B2.MouseButton1Click:connect(function()
  630. if _G.on2 == 1 then
  631. OFF(B2)
  632. else
  633. ON(B2)
  634. game:GetService('RunService').Stepped:wait()
  635. while _G.on2 == 1 do
  636. for i,v in pairs(game:GetService("Workspace")["__THINGS"].Monsters:GetChildren()) do
  637. if v and v.ClassName == "Model" then
  638. local part = v:FindFirstChild("HumanoidRootPart")
  639. if part then
  640. local m = (Root.Position - part.Position).magnitude
  641. if v.Name == "RougeBot" and m < _G.AuraDist then
  642. DMG(85,v)
  643. elseif v.Name == "Robot" and m < _G.AuraDist then
  644. DMG(80,v)
  645. elseif v.Name == "Zombie" and m < _G.AuraDist then
  646. DMG(100,v)
  647. elseif v.Name == "Skeleton" and m < _G.AuraDist then
  648. DMG(80,v)
  649. elseif v.Name == "Tank" and m < _G.AuraDist then
  650. DMG(675,v)
  651. elseif m < _G.AuraDist then
  652. DMG(100,v)
  653. end
  654. end
  655. end
  656. end
  657. game:GetService('RunService').Stepped:wait()
  658. for i,v in pairs(game:GetService("Workspace")["__DEBRIS"]:GetChildren()) do
  659. local ID = v:FindFirstChild("UID")
  660. if ID then
  661. game:GetService('RunService').Stepped:wait()
  662. local A_1 =
  663. {
  664. [1] = ID.Value
  665. }
  666. local Event = game:GetService("Workspace")["__REMOTES"].Game["Redeem Drop"]
  667. Event:FireServer(A_1)
  668. end
  669. end
  670. end
  671. OFF(B2)
  672. end
  673. end)
  674.  
  675. B3.MouseButton1Click:connect(function()
  676. if _G.on3 == 1 then
  677. OFF(B3)
  678. else
  679. ON(B3)
  680. game:GetService('RunService').Stepped:wait()
  681. local search = game.Workspace:FindFirstChild("DeathPart")
  682. if search then
  683. search:Destroy()
  684. end
  685. local DeathP = Instance.new("Part",workspace)
  686. DeathP.Size = Vector3.new(400,8,10)
  687. if KPLocation == 1 then
  688. DeathP.Position = Vector3.new(-70, 5.5, -144)
  689. elseif KPLocation == 2 then
  690. DeathP.Position = Vector3.new(-70, 5.5, -85.2)
  691. elseif KPLocation == 3 then
  692. DeathP.Position = Vector3.new(-70, -1.5, -23.9)
  693. elseif KPLocation == 4 then
  694. DeathP.Position = Vector3.new(-70, -8, 35.8)
  695. end
  696. DeathP.Name = "DeathPart"
  697. DeathP.Color = Color3.fromRGB(0,0,0)
  698. DeathP.Anchored = true
  699. DeathP.Transparency = .75
  700. mobs = {}
  701. while _G.on3 == 1 do
  702. wait()
  703. tbl = DeathP:GetTouchingParts()
  704. if #tbl > 0 then
  705. for i = 1,#tbl do
  706. if tbl[i].Parent ~= "Coin" and tbl[i].Parent ~= "Star" and tbl[i].Parent ~= "Heart" and isin(tbl[i].Parent,mobs) == false then
  707. table.insert(mobs,tbl[i].Parent)
  708. elseif tbl[i].Parent == "Coin" or tbl[i].Parent == "Star" or tbl[i].Parent == "Heart" then
  709. local ID = tbl[i]:FindFirstChild("UID")
  710. if ID then
  711. local A_1 =
  712. {
  713. [1] = ID.Value
  714. }
  715. local Event = game:GetService("Workspace")["__REMOTES"].Game["Redeem Drop"]
  716. Event:FireServer(A_1)
  717. end
  718. end
  719. end
  720. for i = 1,#mobs do
  721. DMG(675,mobs[1])
  722. table.remove(mobs,1)
  723. end
  724. end
  725. end
  726. local search = game.Workspace:FindFirstChild("DeathPart")
  727. if search then
  728. search:Destroy()
  729. end
  730. OFF(B3)
  731. end
  732. end)
  733.  
  734. B4.MouseButton1Click:connect(function()
  735. if _G.on4 == 1 then
  736. OFF(B4)
  737. else
  738. ON(B4)
  739. game:GetService('RunService').Stepped:wait()
  740. newz = z
  741. for a = 1,amount do
  742. if _G.on4 == 1 then
  743. newx = x
  744. newy = y
  745. newz = newz + 4
  746. for i = 1, 90 do
  747. if _G.on4 == 1 then
  748. wait(WT)
  749. newx = newx + 4
  750. place("Wood",newx,y,newz)
  751. newy = y + 4
  752. place("Wood",newx,newy,newz)
  753. end
  754. end
  755. end
  756. end
  757. for i,v in pairs(game:GetService("Workspace")["__DEBRIS"]:GetChildren()) do
  758. if v.Name == "Part" and v.ClassName == "Part" then
  759. v:Destroy()
  760. end
  761. end
  762. OFF(B4)
  763. end
  764. end)
  765.  
  766. B5.MouseButton1Click:connect(function()
  767. if _G.on5 == 1 then
  768. OFF(B5)
  769. else
  770. ON(B5)
  771. game:GetService('RunService').Stepped:wait()
  772. newz = z
  773. for a = 1,amount do
  774. if _G.on5 == 1 then
  775. newx = x
  776. newy = y
  777. newz = newz + 4
  778. for i = 1, 90 do
  779. if _G.on5 == 1 then
  780. wait(WT)
  781. newx = newx + 4
  782. place("Brick",newx,y,newz)
  783. newy = y + 4
  784. place("Brick",newx,newy,newz)
  785. end
  786. end
  787. end
  788. end
  789. for i,v in pairs(game:GetService("Workspace")["__DEBRIS"]:GetChildren()) do
  790. if v.Name == "Part" and v.ClassName == "Part" then
  791. v:Destroy()
  792. end
  793. end
  794. OFF(B5)
  795. end
  796. end)
  797.  
  798. B6.MouseButton1Click:connect(function()
  799. if _G.on6 == 1 then
  800. OFF(B6)
  801. else
  802. ON(B6)
  803. game:GetService('RunService').Stepped:wait()
  804. newz = z
  805. for a = 1,amount do
  806. if _G.on6 == 1 then
  807. newx = x
  808. newy = y
  809. newz = newz + 4
  810. for i = 1, 90 do
  811. if _G.on6 == 1 then
  812. wait(WT)
  813. newx = newx + 4
  814. place("Metal",newx,y,newz)
  815. newy = y + 4
  816. place("Metal",newx,newy,newz)
  817. end
  818. end
  819. end
  820. end
  821. for i,v in pairs(game:GetService("Workspace")["__DEBRIS"]:GetChildren()) do
  822. if v.Name == "Part" and v.ClassName == "Part" then
  823. v:Destroy()
  824. end
  825. end
  826. OFF(B6)
  827. end
  828. end)
  829.  
  830. B7.MouseButton1Click:connect(function()
  831. if _G.on7 == 1 then
  832. OFF(B7)
  833. else
  834. ON(B7)
  835. game:GetService('RunService').Stepped:wait()
  836. --code
  837. OFF(B7)
  838. end
  839. end)
  840.  
  841. B8.MouseButton1Click:connect(function()
  842. if _G.on8 == 1 then
  843. OFF(B8)
  844. else
  845. ON(B8)
  846. game:GetService('RunService').Stepped:wait()
  847. --Code
  848. OFF(B8)
  849. end
  850. end)
  851.  
  852.  
  853. print('loaded')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement