Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- pressedt = false
- function heatexpansion()
- local countdown = 0
- local trailp = Instance.new("Part", attac)
- trailp.Anchored = true
- trailp.Transparency = 1
- trailp.CanCollide = false
- local trail = Instance.new("Trail", trailp)
- trail.Lifetime = 1
- trail.LightEmission = 1
- trail.LightInfluence = 0
- local att = Instance.new("Attachment")
- att.Position = Vector3.new(0,1,0)
- local att2 = att:Clone()
- att2.Position = Vector3.new(0,-1,0)
- att.Parent = trailp
- att2.Parent = trailp
- trail.Attachment0 = att
- trail.Attachment1 = att2
- trail.Color = ColorSequence.new(Color3.new(255,100,0),Color3.new(85,0,255))
- trail.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,0),NumberSequenceKeypoint.new(1,1)})
- trail.FaceCamera = true
- trailp.Position = crown.Position
- trail.Enabled = false
- trailp.Touched:Connect(function(t)
- if t then
- if t.Parent ~= ch then
- if t.Parent:FindFirstChildOfClass("Humanoid") then
- t.Parent:BreakJoints()
- for _,v in pairs(t.Parent:GetChildren()) do
- if v:IsA("Part") or v:IsA("MeshPart") then
- local trail = Instance.new("Trail", v)
- trail.Lifetime = 1
- trail.LightEmission = 1
- trail.LightInfluence = 0
- local att = Instance.new("Attachment")
- att.Position = Vector3.new(0,v.Size.Y/2,0)
- local att2 = att:Clone()
- att2.Position = Vector3.new(0,-(v.Size.Y/2),0)
- att.Parent = v
- att2.Parent = v
- trail.Attachment0 = att
- trail.Attachment1 = att2
- trail.Color = ColorSequence.new(Color3.new(255,100,0),Color3.new(85,0,255))
- trail.Transparency = NumberSequence.new({NumberSequenceKeypoint.new(0,0),NumberSequenceKeypoint.new(1,1)})
- trail.Enabled = true
- v.Velocity = Vector3.new(v.Velocity.X * math.random(-10,10),v.Velocity.Y * math.random(-10,10),v.Velocity.Z * math.random(-10,10))
- game.Debris:AddItem(v, math.random(3,5))
- end
- end
- end
- end
- end
- end)
- --time slowing
- local ended = false
- lastg = workspace.Gravity
- spawn(function()
- repeat swait() game.Workspace.Gravity = 10 until ended = true
- game.Workspace.Gravity = lastg
- end)
- for _,v in pairs(game:GetDescendants()) do
- if v:IsA("Humanoid") and v.Parent ~= ch then
- spawn(function()
- local prevw = v.WalkSpeed
- local prevj = v.JumpPower
- v.Velocity = Vector3.new(v.Velocity.X,v.Velocity.Y + math.random(20,100),v.Velocity.Z)
- repeat swait() v.WalkSpeed = 4 v.JumpPower = 10 until ended = true
- v.JumpPower = prevj
- v.WalkSpeed = prevw
- end)
- end
- end
- repeat swait() trailp.Positon = crown.Position countdown = countdown + 1 until pressedt = true or countdown > 100
- if pressedt == true then
- trail.Enabled = true
- for _,v in pairs(game:GetDescendants()) do
- if v.Name == "HumanoidRootPart" then
- trailp.Position = v.Position
- end
- end
- game.Debris:AddItem(trailp, 1.1)
- trailp.Position = crown.Position
- else
- game.Debris:AddItem(trailp, 0)
- ended = true
- end
- end
Add Comment
Please, Sign In to add comment