Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local player = game.Players.LocalPlayer
- if player then do wait(3)
- local char = player.Character
- local cankill = Instance.new("BoolValue")
- cankill.Name = "CanKill"
- cankill.Value = true
- local box = Instance.new("Part")
- box.Size = Vector3.new(5.5,8,5.5)
- box.Name = "Shield"
- box.CFrame = char.Torso.CFrame
- box.Anchored = true
- box.CanCollide = false
- box.Material = "Neon"
- box.Transparency = 0.75
- box.BrickColor = BrickColor:Red()
- box.Parent = game.Workspace
- cankill.Parent = box
- local a = Instance.new("Part")
- a.Size = Vector3.new(5, 5, 2)
- a.Name = "Shield"
- a.Anchored = true
- a.CanCollide = true
- a.Material = "Neon"
- a.Transparency = 1
- a.BrickColor = BrickColor:Black()
- a.Parent = box
- local b = Instance.new("Part")
- b.Size = Vector3.new(5, 5, 2)
- b.Name = "Shield"
- b.Anchored = true
- b.CanCollide = true
- b.Material = "Neon"
- b.Transparency = 1
- b.BrickColor = BrickColor:Black()
- b.Parent = box
- game:GetService("RunService").RenderStepped:connect(function()
- wait()
- box.CFrame = char.Torso.CFrame
- a.CFrame = char.Torso.CFrame * CFrame.new(0,0,4)
- b.CFrame = char.Torso.CFrame * CFrame.new(0,0,-4)
- char:FindFirstChild("Humanoid")
- char.Humanoid.MaxHealth = math.huge
- char.Humanoid.Health = math.huge
- char.Humanoid.WalkSpeed = 20
- char.Humanoid.JumpPower = 65
- end)
- box.Touched:connect(function(hit)
- if hit.Parent ~= player.Character and cankill.Value == true then
- if hit.Parent:FindFirstChild("Humanoid") then
- hit.Parent:BreakJoints()
- hit.Parent.Humanoid.Health = hit.Parent.Humanoid.Health-25
- for i,body in pairs (hit.Parent:GetChildren()) do
- if body:IsA("Part") then
- body:Remove()
- end
- end
- end
- end end)
- a.Touched:connect(function(hitt)
- hitt:Remove()
- end)
- b.Touched:connect(function(hittt)
- hittt:Remove()
- end)
- player.Chatted:connect(function(c)
- if c == "KillOnTouchEnable" then
- box.BrickColor = BrickColor:Red()
- cankill.Value = true
- else if c == "KillOnTouchDisable"
- then
- box.BrickColor = BrickColor:Black()
- cankill.Value = false
- else if c == "Visible=false" then
- box.Transparency = 1
- else if c == "Visible=true" then
- box.Transparency = 0.75
- else if c == "cmds" then
- print('KillOnTouchEnable, KillOnTouchDisable, Visible=false Visible=true, cnds')
- end end end end end end) end end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement