Advertisement
TROLERMASTERH

AntiDeath

Jan 1st, 2018
573
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.57 KB | None | 0 0
  1. script.Parent = Instance.new("Glue")
  2. local Player = game:GetService("Players").LocalPlayer
  3. local lastpos = {}
  4. Player.Character.Archivable = true
  5. local Clone = Player.Character:Clone()
  6. if Player:FindFirstChild("AntiDeathClone") then
  7. Player:FindFirstChild("AntiDeathClone"):Destroy()
  8. end
  9. Instance.new("Folder", Player).Name = "AntiDeathClone"
  10. Clone.Parent = Player.AntiDeathClone
  11.  
  12. API = {}
  13. API.Gs = function()
  14. local choices = {"a", "b" , "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z"}
  15. local a = choices[math.random(1, #choices)]
  16. local b = choices[math.random(1, #choices)]
  17. local c = choices[math.random(1, #choices)]
  18. local d = choices[math.random(1, #choices)]
  19. local e = choices[math.random(1, #choices)]
  20. local f = choices[math.random(1, #choices)]
  21. local g = choices[math.random(1, #choices)]
  22. local h = choices[math.random(1, #choices)]
  23. local i = choices[math.random(1, #choices)]
  24.  
  25. local str = a..b..c..e..d..e..f..g..h..i
  26. return str
  27. end
  28.  
  29. API.GetObjs = function(parent, typeo)
  30. local objs = {}
  31. for i,v in pairs(parent:GetChildren()) do
  32. if typeo ~= nil then
  33. if v:IsA(typeo) then
  34. table.insert(objs, v)
  35. end
  36. else
  37. table.insert(objs, v)
  38. end
  39. end
  40. return objs
  41. end
  42.  
  43. API.RemoveObjs = function(parent, typeo)
  44. for i,v in pairs(API.getobjs(parent, typeo)) do
  45. v:Remove()
  46. end
  47. end
  48.  
  49. API.GetAllObjs = function(parent, typeo)
  50. local objs = {}
  51. function getobj(object)
  52. if typeo ~= nil then
  53. if object:IsA(typeo) then
  54. table.insert(objs, object)
  55. end
  56. else
  57. table.insert(objs, object)
  58. end
  59. for _, child in ipairs(object:GetChildren()) do
  60. getobj(child)
  61. end
  62. end
  63. getobj(parent)
  64. return objs
  65. end
  66.  
  67. local scriptssss = API.GetAllObjs(Clone, "LocalScript")
  68. for o,script in pairs(scriptssss) do
  69. script.Disabled = true
  70. end
  71.  
  72. Player.CharacterAdded:connect(function(character)
  73. character:WaitForChild("Humanoid").Died:connect(function()
  74. local oldchar = workspace:FindFirstChild(Player.Name)
  75. local newchar = Clone:Clone()
  76. local lastcframe = workspace.CurrentCamera.CFrame
  77. local oldd = lastcframe
  78. newchar.Parent = workspace
  79. newchar:MakeJoints()
  80. Player.Character = newchar
  81. workspace.CurrentCamera.CameraSubject = Player.Character
  82. local scripts = API.GetAllObjs(newchar, "LocalScript")
  83. for o,script in pairs(scripts) do
  84. script.Disabled = false
  85. end
  86. newchar.Torso.CFrame = lastpos
  87. oldchar:Destroy()
  88. wait()
  89. workspace.CurrentCamera.CFrame = oldd
  90. end)
  91. end)
  92.  
  93. while true do
  94. if Player.Character ~= nil then
  95. lastpos = Player.Character.Torso.CFrame
  96. end
  97. wait(0.1)
  98. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement