Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ---------------------------------------------------
- ---------------The mysterious button---------------
- ---------------------------------------------------
- --Made by mrfunnylaughs4. This sure is some weird button.
- local debounce = false
- ---------------------------------------------------
- ---------------------Functions---------------------
- ---------------------------------------------------
- local function SmoothPart(part)
- part.TopSurface = "Smooth"
- part.BottomSurface = "Smooth"
- part.LeftSurface = "Smooth"
- part.RightSurface = "Smooth"
- part.FrontSurface = "Smooth"
- part.BackSurface = "Smooth"
- end
- local function Effect(Length, Type, SizeStart, SizeEnd, Position, Colour, Parent, CanCollide)
- local part = Instance.new("Part")
- part.Name = Type
- part.CFrame = Position
- part.CanCollide = CanCollide or false
- part.Size = SizeStart
- part.Anchored = true
- part.BrickColor = BrickColor.new(tostring(Colour))
- part.Parent = Parent or workspace
- if Type == "Block" then
- SmoothPart(part)
- end
- if Type == "Sphere" then
- part.Shape = Enum.PartType.Ball
- SmoothPart(part)
- end
- if Type == "TwirlSwirl" then
- local mesh = Instance.new("SpecialMesh")
- mesh.MeshType = Enum.MeshType.FileMesh
- mesh.MeshId = "rbxassetid://662585058"
- mesh.Name = "SwirlMesh"
- mesh.Scale = SizeStart / Vector3.new(500, 500, 500)
- mesh.Parent = part
- end
- if Type == "Wave" or Type == "SpiralWave" then
- local mesh = Instance.new("SpecialMesh")
- mesh.MeshType = Enum.MeshType.FileMesh
- mesh.MeshId = "rbxassetid://20329976"
- mesh.Name = "WaveMesh"
- mesh.Scale = SizeStart / Vector3.new(4, 4, 4)
- mesh.Parent = part
- end
- if Type == "MeshSphere" then
- local mesh = Instance.new("SpecialMesh")
- mesh.MeshType = Enum.MeshType.Sphere
- mesh.Parent = part
- SmoothPart(part)
- end
- spawn(function()
- local TwirlAngle = math.random(-250, 250) / 1000
- local WaveAngle = math.random(-500, 500) / 1000
- for i = 1, Length do
- game:GetService("RunService").Heartbeat:Wait()
- part.Transparency = part.Transparency + 1 / Length
- part.Size = part.Size + SizeEnd / Vector3.new(Length, Length, Length)
- if Type == "TwirlSwirl" then
- part.CFrame = part.CFrame * CFrame.Angles(TwirlAngle, TwirlAngle, TwirlAngle)
- part.SwirlMesh.Scale = part.SwirlMesh.Scale + SizeEnd / Vector3.new(Length * 500, Length * 500, Length * 500)
- end
- if Type == "SpiralWave" then
- part.CFrame = part.CFrame * CFrame.Angles(WaveAngle, WaveAngle, WaveAngle)
- part.WaveMesh.Scale = part.WaveMesh.Scale + SizeEnd / Vector3.new(Length * 4, Length * 4, Length * 4)
- end
- if Type == "Wave" then
- part.CFrame = part.CFrame * CFrame.Angles(0, WaveAngle, 0)
- part.WaveMesh.Scale = part.WaveMesh.Scale + SizeEnd / Vector3.new(Length * 4, Length * 4, Length * 4)
- end
- end
- part:Destroy()
- end)
- end
- ---------------------------------------------------
- -----------------Making the button and home of loseers-----------------
- ---------------------------------------------------
- local model = Instance.new("Model")
- model.Name = "Button"
- model.Parent = workspace
- local base = Instance.new("Part")
- base.Name = "Base"
- base.Size = Vector3.new(1, 4, 4)
- base.Shape = Enum.PartType.Cylinder
- base.CFrame = CFrame.new(0, 0.5, 0, 0, 0, 1, -1, 0, 0, 0, -1, 0)
- base.BrickColor = BrickColor.new("Medium stone grey")
- base.Anchored = true
- base.Locked = true
- SmoothPart(base)
- base.Parent = model
- local button = Instance.new("Part")
- button.Name = "Button"
- button.Size = Vector3.new(1, 3.4, 3.4)
- button.Shape = Enum.PartType.Cylinder
- button.CFrame = CFrame.new(1.49011612e-08, 0.799999952, 0, -0, -0, 1, -1, -0, 0, -0, -1, 0)
- button.BrickColor = BrickColor.new("Bright red")
- button.Anchored = true
- button.Locked = true
- SmoothPart(button)
- button.Parent = model
- local click = Instance.new("ClickDetector")
- click.Name = "MouseClickDetect"
- click.MaxActivationDistance = 8
- click.Parent = button
- local Model = Instance.new("Model", workspace)
- local part = Instance.new("Part")
- local part_2 = Instance.new("Part")
- local part_3 = Instance.new("Part")
- local part_4 = Instance.new("Part")
- local part_5 = Instance.new("Part")
- local tele = Instance.new("Part")
- local part_6 = Instance.new("Part")
- local part_7 = Instance.new("Part")
- local part_8 = Instance.new("Part")
- local surfacelight = Instance.new("SurfaceLight")
- local part_9 = Instance.new("Part")
- local part_10 = Instance.new("Part")
- local part_11 = Instance.new("Part")
- local decal = Instance.new("Decal")
- local part_12 = Instance.new("Part")
- local part_13 = Instance.new("Part")
- local part_14 = Instance.new("Part")
- local decal_2 = Instance.new("Decal")
- local part_15 = Instance.new("Part")
- local part_16 = Instance.new("Part")
- local part_17 = Instance.new("Part")
- local part_18 = Instance.new("Part")
- local part_19 = Instance.new("Part")
- local part_20 = Instance.new("Part")
- local part_21 = Instance.new("Part")
- part.Anchored = true
- part.Size = Vector3.new(1, 25, 56)
- part.BottomSurface = Enum.SurfaceType.Smooth
- part.Material = Enum.Material.Wood
- part.Color = Color3.new(0.627451, 0.372549, 0.207843)
- part.TopSurface = Enum.SurfaceType.Smooth
- part.BrickColor = BrickColor.new("Dark orange")
- part.Parent = Model
- part.CFrame = CFrame.new(2873.5, 1692.5, -5646)
- part_2.Anchored = true
- part_2.Size = Vector3.new(29, 25, 1)
- part_2.BottomSurface = Enum.SurfaceType.Smooth
- part_2.Material = Enum.Material.Wood
- part_2.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_2.TopSurface = Enum.SurfaceType.Smooth
- part_2.BrickColor = BrickColor.new("Really black")
- part_2.Parent = Model
- part_2.CFrame = CFrame.new(2887.5, 1692.5, -5617.5)
- part_3.Anchored = true
- part_3.Size = Vector3.new(1, 25, 56)
- part_3.BottomSurface = Enum.SurfaceType.Smooth
- part_3.Material = Enum.Material.Wood
- part_3.Color = Color3.new(0.627451, 0.372549, 0.207843)
- part_3.TopSurface = Enum.SurfaceType.Smooth
- part_3.BrickColor = BrickColor.new("Dark orange")
- part_3.Parent = Model
- part_3.CFrame = CFrame.new(2901.5, 1692.5, -5646)
- part_4.Anchored = true
- part_4.Size = Vector3.new(28, 1, 22)
- part_4.BottomSurface = Enum.SurfaceType.Smooth
- part_4.Material = Enum.Material.Wood
- part_4.Color = Color3.new(0.627451, 0.372549, 0.207843)
- part_4.TopSurface = Enum.SurfaceType.Smooth
- part_4.BrickColor = BrickColor.new("Dark orange")
- part_4.Parent = Model
- part_4.CFrame = CFrame.new(2888, 1704.5, -5629)
- part_5.Anchored = true
- part_5.Size = Vector3.new(28, 1, 24)
- part_5.BottomSurface = Enum.SurfaceType.Smooth
- part_5.Material = Enum.Material.Wood
- part_5.Color = Color3.new(0.627451, 0.372549, 0.207843)
- part_5.TopSurface = Enum.SurfaceType.Smooth
- part_5.BrickColor = BrickColor.new("Dark orange")
- part_5.Parent = Model
- part_5.CFrame = CFrame.new(2888, 1704.5, -5662)
- tele.Anchored = true
- tele.CanCollide = false
- tele.Size = Vector3.new(1, 1, 1)
- tele.Orientation = Vector3.new(0, 90, 0)
- tele.BottomSurface = Enum.SurfaceType.Smooth
- tele.Material = Enum.Material.Wood
- tele.Name = "TELE"
- tele.Transparency = 1
- tele.TopSurface = Enum.SurfaceType.Smooth
- tele.BrickColor = BrickColor.new("Really black")
- tele.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- tele.Parent = Model
- tele.CFrame = CFrame.new(2887, 1737.5, -5645) * CFrame.Angles(0, 1.571, 0)
- part_6.Anchored = true
- part_6.Size = Vector3.new(1, 43, 10)
- part_6.BottomSurface = Enum.SurfaceType.Smooth
- part_6.Material = Enum.Material.Wood
- part_6.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_6.TopSurface = Enum.SurfaceType.Smooth
- part_6.BrickColor = BrickColor.new("Really black")
- part_6.Parent = Model
- part_6.CFrame = CFrame.new(2881.5, 1726.5, -5645)
- part_7.Anchored = true
- part_7.Size = Vector3.new(29, 1, 56)
- part_7.BottomSurface = Enum.SurfaceType.Smooth
- part_7.Material = Enum.Material.Wood
- part_7.Color = Color3.new(0.627451, 0.372549, 0.207843)
- part_7.TopSurface = Enum.SurfaceType.Smooth
- part_7.BrickColor = BrickColor.new("Dark orange")
- part_7.Parent = Model
- part_7.CFrame = CFrame.new(2887.5, 1680.5, -5646)
- part_8.Anchored = true
- part_8.CanCollide = false
- part_8.Size = Vector3.new(27, 1, 54)
- part_8.Material = Enum.Material.Wood
- part_8.BottomSurface = Enum.SurfaceType.Smooth
- part_8.BrickColor = BrickColor.new("Dark orange")
- part_8.TopSurface = Enum.SurfaceType.Smooth
- part_8.Transparency = 1
- part_8.Color = Color3.new(0.627451, 0.372549, 0.207843)
- part_8.Parent = Model
- part_8.CFrame = CFrame.new(2887.5, 1681.5, -5646)
- surfacelight.Angle = 180
- surfacelight.Range = 60
- surfacelight.Brightness = 10
- surfacelight.Face = Enum.NormalId.Top
- surfacelight.Parent = part_8
- part_9.Anchored = true
- part_9.Size = Vector3.new(1, 43, 10)
- part_9.Orientation = Vector3.new(0, 90, 0)
- part_9.Material = Enum.Material.Wood
- part_9.BottomSurface = Enum.SurfaceType.Smooth
- part_9.BrickColor = BrickColor.new("Really black")
- part_9.TopSurface = Enum.SurfaceType.Smooth
- part_9.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_9.Parent = Model
- part_9.CFrame = CFrame.new(2887, 1726.5, -5639.5) * CFrame.Angles(0, 1.571, 0)
- part_10.Anchored = true
- part_10.Size = Vector3.new(1, 43, 10)
- part_10.Orientation = Vector3.new(0, 90, 0)
- part_10.Material = Enum.Material.Wood
- part_10.BottomSurface = Enum.SurfaceType.Smooth
- part_10.BrickColor = BrickColor.new("Really black")
- part_10.TopSurface = Enum.SurfaceType.Smooth
- part_10.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_10.Parent = Model
- part_10.CFrame = CFrame.new(2887, 1726.5, -5650.5) * CFrame.Angles(0, 1.571, 0)
- part_11.Anchored = true
- part_11.Size = Vector3.new(15, 12, 1)
- part_11.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_11.BrickColor = BrickColor.new("Really black")
- part_11.BottomSurface = Enum.SurfaceType.Smooth
- part_11.TopSurface = Enum.SurfaceType.Smooth
- part_11.Parent = Model
- part_11.CFrame = CFrame.new(2888.5, 1694, -5673.5)
- decal.Texture = "http://www.roblox.com/asset/?id=560997999"
- decal.Face = Enum.NormalId.Back
- decal.Parent = part_11
- part_12.Anchored = true
- part_12.Size = Vector3.new(9, 1, 56)
- part_12.BottomSurface = Enum.SurfaceType.Smooth
- part_12.Material = Enum.Material.Wood
- part_12.Color = Color3.new(0.627451, 0.372549, 0.207843)
- part_12.TopSurface = Enum.SurfaceType.Smooth
- part_12.BrickColor = BrickColor.new("Dark orange")
- part_12.Parent = Model
- part_12.CFrame = CFrame.new(2877.5, 1704.5, -5646)
- part_13.Anchored = true
- part_13.Size = Vector3.new(1, 25, 56)
- part_13.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_13.BrickColor = BrickColor.new("Really black")
- part_13.BottomSurface = Enum.SurfaceType.Smooth
- part_13.TopSurface = Enum.SurfaceType.Smooth
- part_13.Parent = Model
- part_13.CFrame = CFrame.new(2902.5, 1692.5, -5646)
- part_14.Anchored = true
- part_14.Size = Vector3.new(18, 11, 1)
- part_14.Orientation = Vector3.new(0, 180, 0)
- part_14.BottomSurface = Enum.SurfaceType.Smooth
- part_14.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_14.TopSurface = Enum.SurfaceType.Smooth
- part_14.BrickColor = BrickColor.new("Really black")
- part_14.Parent = Model
- part_14.CFrame = CFrame.new(2888, 1693.5, -5618.5) * CFrame.Angles(-3.142, 0, -3.142)
- decal_2.Texture = "http://www.roblox.com/asset/?id=2197740511"
- decal_2.Face = Enum.NormalId.Back
- decal_2.Parent = part_14
- part_15.Anchored = true
- part_15.Size = Vector3.new(29, 25, 1)
- part_15.BottomSurface = Enum.SurfaceType.Smooth
- part_15.Material = Enum.Material.Wood
- part_15.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_15.TopSurface = Enum.SurfaceType.Smooth
- part_15.BrickColor = BrickColor.new("Really black")
- part_15.Parent = Model
- part_15.CFrame = CFrame.new(2887.5, 1692.5, -5674.5)
- part_16.Anchored = true
- part_16.Size = Vector3.new(29, 25, 1)
- part_16.BottomSurface = Enum.SurfaceType.Smooth
- part_16.Material = Enum.Material.Wood
- part_16.Color = Color3.new(0.627451, 0.372549, 0.207843)
- part_16.TopSurface = Enum.SurfaceType.Smooth
- part_16.BrickColor = BrickColor.new("Dark orange")
- part_16.Parent = Model
- part_16.CFrame = CFrame.new(2887.5, 1692.5, -5618.5)
- part_17.Anchored = true
- part_17.Size = Vector3.new(10, 1, 56)
- part_17.BottomSurface = Enum.SurfaceType.Smooth
- part_17.Material = Enum.Material.Wood
- part_17.Color = Color3.new(0.627451, 0.372549, 0.207843)
- part_17.TopSurface = Enum.SurfaceType.Smooth
- part_17.BrickColor = BrickColor.new("Dark orange")
- part_17.Parent = Model
- part_17.CFrame = CFrame.new(2897, 1704.5, -5646)
- part_18.Anchored = true
- part_18.Size = Vector3.new(1, 25, 56)
- part_18.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_18.BrickColor = BrickColor.new("Really black")
- part_18.BottomSurface = Enum.SurfaceType.Smooth
- part_18.TopSurface = Enum.SurfaceType.Smooth
- part_18.Parent = Model
- part_18.CFrame = CFrame.new(2872.5, 1692.5, -5646)
- part_19.Anchored = true
- part_19.Size = Vector3.new(29, 25, 1)
- part_19.BottomSurface = Enum.SurfaceType.Smooth
- part_19.Material = Enum.Material.Wood
- part_19.Color = Color3.new(0.627451, 0.372549, 0.207843)
- part_19.TopSurface = Enum.SurfaceType.Smooth
- part_19.BrickColor = BrickColor.new("Dark orange")
- part_19.Parent = Model
- part_19.CFrame = CFrame.new(2887.5, 1692.5, -5673.5)
- part_20.Anchored = true
- part_20.Size = Vector3.new(1, 43, 10)
- part_20.BottomSurface = Enum.SurfaceType.Smooth
- part_20.Material = Enum.Material.Wood
- part_20.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_20.TopSurface = Enum.SurfaceType.Smooth
- part_20.BrickColor = BrickColor.new("Really black")
- part_20.Parent = Model
- part_20.CFrame = CFrame.new(2892.5, 1726.5, -5645)
- part_21.Anchored = true
- part_21.Size = Vector3.new(12, 1, 12)
- part_21.Orientation = Vector3.new(0, 90, 0)
- part_21.Material = Enum.Material.Wood
- part_21.BottomSurface = Enum.SurfaceType.Smooth
- part_21.BrickColor = BrickColor.new("Really black")
- part_21.TopSurface = Enum.SurfaceType.Smooth
- part_21.Color = Color3.new(0.0666667, 0.0666667, 0.0666667)
- part_21.Parent = Model
- part_21.CFrame = CFrame.new(2887, 1747.5, -5645) * CFrame.Angles(0, 1.571, 0)
- ---------------------------------------------------
- ----------------------Attacks----------------------
- ---------------------------------------------------
- game:GetService("RunService").Heartbeat:Connect(function()
- if not click:FindFirstChild("EventHooked") then
- local val = Instance.new("BoolValue")
- val.Name = "EventHooked"
- val.Parent = click
- click.MouseClick:Connect(function(player)
- if debounce == false then
- debounce = true
- local sound = Instance.new("Sound")
- sound.SoundId = "rbxassetid://1677936333"
- sound.Volume = 5
- sound.Parent = button
- sound:Play()
- button.CFrame = button.CFrame + Vector3.new(0, -0.15, 0)
- wait(0.2)
- button.CFrame = button.CFrame + Vector3.new(0, 0.15, 0)
- wait(0.05)
- local sound2 = Instance.new("Sound")
- sound2.SoundId = "rbxassetid://1274525620"
- sound2.Volume = 5
- sound2.Parent = button
- sound2:Play()
- wait(1.55)
- sound:Destroy()
- sound2:Destroy()
- local choice = math.random(1, 5)
- if choice == 1 then
- local Char = player.Character
- local sound = Instance.new("Sound")
- sound.SoundId = "rbxassetid://130972023"
- sound.Volume = 5
- sound.Parent = Char.HumanoidRootPart
- sound:Play()
- Effect(40, "Sphere", Vector3.new(2, 2, 2), Vector3.new(15, 15, 15), Char.HumanoidRootPart.CFrame, BrickColor.new("Really black"), Char)
- for i = 1, 4 do
- Effect(40, "SpiralWave", Vector3.new(10, 2, 10), Vector3.new(40, 8, 40), Char.HumanoidRootPart.CFrame, BrickColor.new("Really black"), Char)
- end
- for i,v in pairs(Char:GetChildren()) do
- if v:IsA("BasePart") and not v:IsA("Terrain") then
- v:BreakJoints()
- v.Velocity = Vector3.new(math.random(-25, 25), 30, math.random(-25, 25))
- end
- end
- elseif choice == 2 then
- local Char = player.Character
- local sound = Instance.new("Sound")
- sound.SoundId = "rbxassetid://1368583274"
- sound.Volume = 5
- sound.Parent = Char.HumanoidRootPart
- sound:Play()
- for i = 1, 120 do
- game:GetService("RunService").Heartbeat:Wait()
- sound.Volume = sound.Volume - 5 / 120
- Effect(15, "Wave", Vector3.new(7, 1, 7), Vector3.new(20, 4, 20), Char.HumanoidRootPart.CFrame + Vector3.new(0, -2.5, 0), BrickColor.new("Mid gray"), Char)
- end
- sound:Destroy()
- local sound = Instance.new("Sound")
- sound.SoundId = "rbxassetid://165970126"
- sound.Volume = 2
- sound.Parent = Char.HumanoidRootPart
- sound:Play()
- Effect(20, "MeshSphere", Vector3.new(5, 15, 5), Vector3.new(8, 90, 8), Char.HumanoidRootPart.CFrame, BrickColor.new("Institutional white"), Char)
- for i = 1, 4 do
- Effect(30, "Wave", Vector3.new(7, 1, 7), Vector3.new(40, 8, 40), Char.HumanoidRootPart.CFrame + Vector3.new(0, -2.5, 0), BrickColor.new("Mid gray"), Char)
- end
- local vel = Instance.new("BodyVelocity")
- vel.MaxForce = Vector3.new(1e9, 1e9, 1e9)
- vel.Velocity = Vector3.new(0, 300, 0)
- vel.Parent = Char.HumanoidRootPart
- spawn(function()
- wait(0.5)
- vel:Destroy()
- end)
- elseif choice == 3 then
- local Char = player.Character
- local hole = Instance.new("Part")
- hole.Name = "Hole"
- hole.Color = Color3.new(0, 0, 0)
- hole.Shape = Enum.PartType.Cylinder
- hole.CFrame = Char.HumanoidRootPart.CFrame * CFrame.new(0, -3.04, 0) * CFrame.Angles(0, 0, math.pi / 2)
- hole.Size = Vector3.new(0.1, 0, 0)
- hole.Anchored = true
- hole.Locked = true
- hole.Material = Enum.Material.Neon
- hole.CanCollide = false
- SmoothPart(hole)
- hole.Parent = Char
- Char.Head.Anchored = true
- for i = 1, 35 do
- game:GetService("RunService").Heartbeat:Wait()
- hole.Size = hole.Size + Vector3.new(0, 0.2 * Char.HumanoidRootPart.Size.Z, 0.2 * Char.HumanoidRootPart.Size.Z)
- end
- local sound = Instance.new("Sound")
- sound.SoundId = "rbxassetid://838038142"
- sound.Volume = 2
- sound.Parent = Char.HumanoidRootPart
- sound:Play()
- repeat
- game:GetService("RunService").Heartbeat:Wait()
- Char:SetPrimaryPartCFrame(Char.Head.CFrame * CFrame.new(0, -0.05, 0))
- hole.CFrame = hole.CFrame + Vector3.new(0, 0.05, 0)
- until Char.HumanoidRootPart.Position.Y < hole.Position.Y - 3.4 * Char.HumanoidRootPart.Size.Z
- sound:Destroy()
- for i = 1, 35 do
- game:GetService("RunService").Heartbeat:Wait()
- hole.Size = hole.Size - Vector3.new(0, 0.2 * Char.HumanoidRootPart.Size.Z, 0.2 * Char.HumanoidRootPart.Size.Z)
- end
- hole:Destroy()
- Char:BreakJoints()
- elseif choice == 4 then
- local Char = player.Character
- local sound = Instance.new("Sound")
- sound.SoundId = "rbxassetid://130972023"
- sound.Volume = 5
- sound.Parent = Char.HumanoidRootPart
- sound:Play()
- if Char:FindFirstChildOfClass("Humanoid") then
- for i = 1, 5 do
- Effect(30, "Wave", Vector3.new(7, 1, 7), Vector3.new(20, 4, 20), Char.HumanoidRootPart.CFrame + Vector3.new(0, -2.5, 0), BrickColor.new("Mid gray"), Char)
- end
- Char:FindFirstChildOfClass("Humanoid").PlatformStand = true
- else
- for i = 1, 5 do
- Effect(30, "Wave", Vector3.new(7, 1, 7), Vector3.new(20, 4, 20), Char.HumanoidRootPart.CFrame + Vector3.new(0, -2.5, 0), BrickColor.new("Mid gray"), Char)
- end
- local bodyforce = Instance.new("BodyForce")
- bodyforce.Force = Vector3.new(0, -500000, 0)
- bodyforce.Parent = Char.Head
- end
- elseif choice == 5 then
- local Char = player.Character
- local hole = Instance.new("Part")
- hole.Name = "Hole"
- hole.Color = Color3.new(0, 0, 0)
- hole.Shape = Enum.PartType.Cylinder
- hole.CFrame = Char.HumanoidRootPart.CFrame * CFrame.new(0, -3.04, 0) * CFrame.Angles(0, 0, math.pi / 2)
- hole.Size = Vector3.new(0.1, 0, 0)
- hole.Anchored = true
- hole.Locked = true
- hole.Material = Enum.Material.Neon
- hole.CanCollide = false
- SmoothPart(hole)
- hole.Parent = Char
- Char.Head.Anchored = true
- for i = 1, 35 do
- game:GetService("RunService").Heartbeat:Wait()
- hole.Size = hole.Size + Vector3.new(0, 0.2 * Char.HumanoidRootPart.Size.Z, 0.2 * Char.HumanoidRootPart.Size.Z)
- end
- local sound = Instance.new("Sound")
- sound.SoundId = "rbxassetid://838038142"
- sound.Volume = 2
- sound.Parent = Char.HumanoidRootPart
- sound:Play()
- repeat
- game:GetService("RunService").Heartbeat:Wait()
- Char:SetPrimaryPartCFrame(Char.Head.CFrame * CFrame.new(0, -0.05, 0))
- hole.CFrame = hole.CFrame + Vector3.new(0, 0.05, 0)
- until Char.HumanoidRootPart.Position.Y < hole.Position.Y - 3.4 * Char.HumanoidRootPart.Size.Z
- sound:Destroy()
- for i = 1, 35 do
- game:GetService("RunService").Heartbeat:Wait()
- hole.Size = hole.Size - Vector3.new(0, 0.2 * Char.HumanoidRootPart.Size.Z, 0.2 * Char.HumanoidRootPart.Size.Z)
- end
- hole:Destroy()
- Char.Head.Anchored = false
- Char:moveTo(tele.Position)
- end
- debounce = false
- end
- end)
- end
- end)
- ---------------------------------------------------
- --------------------Wrapping up--------------------
- ---------------------------------------------------
- while game:GetService("RunService").Heartbeat:Wait() do
- if model.Parent ~= workspace then
- model = Instance.new("Model")
- model.Name = "Button"
- base = Instance.new("Part")
- base.Name = "Base"
- base.Size = Vector3.new(1, 4, 4)
- base.Shape = Enum.PartType.Cylinder
- base.CFrame = CFrame.new(0, 0.5, 0, 0, 0, 1, -1, 0, 0, 0, -1, 0)
- base.BrickColor = BrickColor.new("Medium stone grey")
- base.Anchored = true
- base.Locked = true
- SmoothPart(base)
- base.Parent = model
- button = Instance.new("Part")
- button.Name = "Button"
- button.Size = Vector3.new(1, 3.4, 3.4)
- button.Shape = Enum.PartType.Cylinder
- button.CFrame = CFrame.new(1.49011612e-08, 0.799999952, 0, -0, -0, 1, -1, -0, 0, -0, -1, 0)
- button.BrickColor = BrickColor.new("Bright red")
- button.Anchored = true
- button.Locked = true
- SmoothPart(button)
- button.Parent = model
- click = Instance.new("ClickDetector")
- click.Name = "MouseClickDetect"
- click.MaxActivationDistance = 8
- click.Parent = button
- model.Parent = workspace
- end
- if base.Parent ~= model then
- base = Instance.new("Part")
- base.Name = "Base"
- base.Size = Vector3.new(1, 4, 4)
- base.Shape = Enum.PartType.Cylinder
- base.CFrame = CFrame.new(0, 0.5, 0, 0, 0, 1, -1, 0, 0, 0, -1, 0)
- base.BrickColor = BrickColor.new("Medium stone grey")
- base.Anchored = true
- base.Locked = true
- SmoothPart(base)
- base.Parent = model
- end
- if button.Parent ~= model then
- button = Instance.new("Part")
- button.Name = "Button"
- button.Size = Vector3.new(1, 3.4, 3.4)
- button.Shape = Enum.PartType.Cylinder
- button.CFrame = CFrame.new(1.49011612e-08, 0.799999952, 0, -0, -0, 1, -1, -0, 0, -0, -1, 0)
- button.BrickColor = BrickColor.new("Bright red")
- button.Anchored = true
- button.Locked = true
- SmoothPart(button)
- button.Parent = model
- end
- if click.Parent ~= button then
- click = Instance.new("ClickDetector")
- click.Name = "MouseClickDetect"
- click.MaxActivationDistance = 8
- click.Parent = button
- model.Parent = workspace
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement