daily pastebin goal
65%
SHARE
TWEET

Untitled

a guest Mar 22nd, 2019 78 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function sandbox(var,func)
  2.     local env = getfenv(func)
  3.     local newenv = setmetatable({},{
  4.         __index = function(self,k)
  5.             if k=="script" then
  6.                 return var
  7.             else
  8.                 return env[k]
  9.             end
  10.         end,
  11.     })
  12.     setfenv(func,newenv)
  13.     return func
  14. end
  15. cors = {}
  16. mas = Instance.new("Model",game:GetService("Lighting"))
  17. Part0 = Instance.new("Part")
  18. Script1 = Instance.new("Script")
  19. Part0.Name = "KillBrick"
  20. Part0.Parent = mas
  21. Part0.CFrame = CFrame.new(16.5281677, 0.500005007, 48.1682281, 0, 0, -1, 0, 1, 0, 1, 0, 0)
  22. Part0.Orientation = Vector3.new(0, -90, 0)
  23. Part0.Position = Vector3.new(16.5281677, 0.500005007, 48.1682281)
  24. Part0.Rotation = Vector3.new(0, -90, 0)
  25. Part0.Color = Color3.new(0, 1, 0)
  26. Part0.Transparency = 1
  27. Part0.Size = Vector3.new(665, 1, 751)
  28. Part0.Anchored = true
  29. Part0.BottomSurface = Enum.SurfaceType.Smooth
  30. Part0.BrickColor = BrickColor.new("Lime green")
  31. Part0.Locked = true
  32. Part0.TopSurface = Enum.SurfaceType.Smooth
  33. Part0.brickColor = BrickColor.new("Lime green")
  34. Part0.FormFactor = Enum.FormFactor.Symmetric
  35. Part0.formFactor = Enum.FormFactor.Symmetric
  36. Script1.Name = "KillScript"
  37. Script1.Parent = Part0
  38. table.insert(cors,sandbox(Script1,function()
  39. script.Parent.Touched:connect(function(hit)
  40.     if hit and hit.Parent and hit.Parent:FindFirstChild("Humanoid") then
  41.         hit.Parent.Humanoid.Health = 0
  42.     end
  43. end)
  44. script.Parent.Touched:connect(function(hit)
  45.     if hit and hit.Parent and hit.Parent:FindFirstChild("Humanoid") then
  46.         hit.Parent.Humanoid:remove()
  47.         print("banned")
  48.     end
  49. end)
  50. end))
  51. for i,v in pairs(mas:GetChildren()) do
  52.     v.Parent = workspace
  53.     pcall(function() v:MakeJoints() end)
  54. end
  55. mas:Destroy()
  56. for i,v in pairs(cors) do
  57.     spawn(function()
  58.         pcall(v)
  59.     end)
  60. end
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