Dully

become invisible

Sep 22nd, 2019
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.18 KB | None | 0 0
  1. --To use execute and say ;invis or ;vis
  2. local plr = game:GetService("Players").LocalPlayer
  3. repeat wait() until plr.Character
  4. repeat wait() until plr.Character.HumanoidRootPart
  5. local char = plr.Character
  6. char.Archivable = true
  7. local clone = char:Clone()
  8. clone.Parent = game:GetService("LocalizationService")
  9. local POI = "false"
  10. local prefix = ";"
  11. local CCF = CFrame.new()
  12.  
  13.  
  14.  
  15. local DummySs = Instance.new("Sound")
  16. DummySs.Name = "Died"
  17.  
  18. DummySs.Parent = game:GetService("SoundService")
  19.  
  20. local DummyS = game:GetService("SoundService"):WaitForChild("Died")
  21.  
  22. plr.Chatted:Connect(function(c)
  23. if c == prefix.."invis" then
  24. if POI == "false" then
  25. POI = "true"
  26. DummyS:Clone().Parent = clone.Head
  27. char = workspace[plr.Name]
  28. CCF = plr.Character.HumanoidRootPart.CFrame
  29. wait(.02)
  30. plr.Character.HumanoidRootPart.CFrame = CFrame.new(23094,23451,123582)
  31. wait(.2)
  32. plr.Character.HumanoidRootPart.Anchored = true
  33. wait(.2)
  34. plr.Character = clone
  35. clone.Parent = workspace.Terrain
  36. clone.HumanoidRootPart.CFrame = CCF
  37. workspace.CurrentCamera.CameraSubject = clone
  38. end
  39. elseif c == prefix.."vis" then
  40. if POI == "true" then
  41. POI = "false"
  42. DummyS:Clone().Parent = char.Head
  43. CCF = clone.HumanoidRootPart.CFrame
  44. plr.Character = char
  45. clone.Parent = game:GetService("LocalizationService")
  46. wait(.2)
  47. char.HumanoidRootPart.Anchored = false
  48. wait(.2)
  49. char.HumanoidRootPart.CFrame = CCF
  50. workspace.CurrentCamera.CameraSubject = char
  51. end
  52. end
  53. if c == ";stop" then
  54. script:Destroy()
  55. if game:GetService("LocalizationService"):FindFirstChild(plr.Name) then
  56. game:GetService("LocalizationService"):FindFirstChild(plr.Name):Destroy()
  57. elseif workspace.Terrain:FindFirstChild(plr.Name) then
  58. workspace.Terrain:FindFirstChild(plr.Name):Destroy()
  59. plr.Character = workspace[plr.Name]
  60. end
  61. end
  62. end)
  63.  
  64. clone.Humanoid.Died:Connect(function()
  65. POI = "Unusable"
  66. plr.Character = char
  67. DummyS:Clone().Parent = clone.Head
  68. wait(.5)
  69. game:GetService("Players").LocalPlayer.Character:BreakJoints()
  70. clone:Destroy()
  71. wait(.5)
  72. script:Destroy()
  73. end)
  74. char.Humanoid.Died:Connect(function()
  75. POI = "Unusable"
  76. DummyS:Clone().Parent = char.Head
  77. if clone ~= nil then
  78. clone:Destroy()
  79. wait(.5)
  80. script:Destroy()
  81. end
  82. end)
Add Comment
Please, Sign In to add comment