TheUnknownDiscord

afk

Nov 6th, 2021 (edited)
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.04 KB | None | 0 0
  1. oldparent = owner.Character.Parent
  2. oldcf = owner.Character.HumanoidRootPart.CFrame
  3. script.Parent = game.Workspace
  4. task.wait()
  5. owner.Character.Parent = script
  6. local billboard = Instance.new("BillboardGui", owner.Character.Head)
  7. billboard.Adornee = owner.Character.Head
  8. billboard.StudsOffset = Vector3.new(-1, 2.5, 0)
  9. billboard.Size = UDim2.new(2,0,1,0)
  10. billboard.Name = "chat"
  11. local text = Instance.new("TextBox", billboard)
  12. text.BackgroundTransparency = 1
  13. text.TextStrokeTransparency = 0
  14. text.TextSize = 25
  15. text.TextStrokeColor3 = Color3.fromRGB(0,0,0)
  16. text.Size = billboard.Size
  17. text.Font = "SpecialElite"
  18. text.TextColor3 = owner.Character.Torso.Color
  19. text.Text = owner.Name.." / "..owner.Character.Humanoid.DisplayName.." Is AFK"
  20. owner.Character.HumanoidRootPart.Anchored = true
  21. local me = {}
  22. owner.Character.Archivable = true
  23. table.insert(me,owner.Character:Clone())
  24. local replicating = false
  25. replicate = function()
  26.  
  27. replicating = true
  28. script:ClearAllChildren()
  29. local clone = me[1]
  30. clone.Parent = script
  31. replicating = false
  32. end
  33.  
  34. script.ChildRemoved:connect(function(a)
  35.  
  36. if replicating == false then
  37. replicate()
  38. end
  39. end
  40. )
  41. wait()
  42. replicate()
  43. wait()
  44. owner.Character.Parent = nil
  45. owner.Chatted:Connect(function(msg)
  46. if string.lower(msg) == "-reset" then
  47. wait()
  48. owner:LoadCharacter()
  49. owner.Character.HumanoidRootPart.CFrame = oldcf
  50. owner.Character.HumanoidRootPart.Anchored = false
  51. wait()
  52. script:Destroy()
  53. end
  54. end)
  55. local screengui2 = Instance.new("ScreenGui", owner:findFirstChildOfClass("PlayerGui"))
  56. screengui2.ResetOnSpawn = true
  57. screengui2.Name = "youfailed2"
  58. local tl3 = Instance.new("TextLabel", screengui2)
  59. tl3.Size = UDim2.new(1,0,1,0)
  60. tl3.AnchorPoint = Vector2.new(1, 1)
  61. tl3.Position = UDim2.new(1, 0, 1, 0)
  62. tl3.Text = "Do -reset to respawn"
  63. tl3.BackgroundTransparency = 1
  64. tl3.TextTransparency = 0
  65. tl3.TextColor3 = Color3.new(0.5, 0.5, 0.5)
  66. tl3.TextSize = 50
Add Comment
Please, Sign In to add comment