Advertisement
Guest User

Untitled

a guest
Feb 20th, 2020
704
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.13 KB | None | 0 0
  1. RobloxianLife = {}
  2. RobloxianLife.GamepassId = nil
  3.  
  4. local runService = game:GetService("RunService")
  5.  
  6. local plr = game:GetService("Players").LocalPlayer
  7.  
  8. RobloxianLife.Initialize = function(slf, id)
  9. GamepassId = id
  10. end
  11.  
  12. local function GiveTool(...) return workspace.GiveTool:FireServer(...) end
  13.  
  14. local function Effect(...) return workspace.Effect:FireServer(...) end
  15.  
  16. local function SetRPName(name)
  17. workspace.GuiEvent:FireServer(name)
  18. end
  19.  
  20. RobloxianLife.SetLocalProperty = function(slf, obj, prop, val)
  21. local waitornot = false
  22.  
  23. if not GamepassId then
  24. return
  25. end
  26. if not obj:IsDescendantOf(plr.Character) then
  27. return
  28. end
  29. if not plr.Backpack:FindFirstChild("PompousTheCloud") and not plr.Character:FindFirstChild("PompousTheCloud") then
  30. GiveTool(GamepassId, "PompousTheCloud")
  31. plr.Backpack:WaitForChild("PompousTheCloud").Parent = plr.Character
  32.  
  33. plr.Character:WaitForChild("PompousTheCloud"):WaitForChild("ServerControl"):InvokeServer(
  34. "SetProperty",
  35. {["Value"] = 0, ["Object"] = plr.Character.PompousTheCloud.Handle.Mesh, ["Property"] = "MeshId"}
  36. )
  37. plr.Character:WaitForChild("PompousTheCloud"):WaitForChild("ServerControl"):InvokeServer(
  38. "SetProperty",
  39. {["Value"] = 1, ["Object"] = plr.Character.PompousTheCloud.Handle, ["Property"] = "Transparency"}
  40. )
  41. plr.Character:WaitForChild("PompousTheCloud"):WaitForChild("ServerControl"):InvokeServer(
  42. "SetProperty",
  43. {["Value"] = true, ["Object"] = plr.Character.PompousTheCloud.LocalScript, ["Property"] = "Disabled"}
  44. )
  45. plr.Character:WaitForChild("PompousTheCloud"):WaitForChild("ServerControl"):InvokeServer(
  46. "SetProperty",
  47. {["Value"] = false, ["Object"] = plr.Character.PompousTheCloud, ["Property"] = "RequiresHandle"}
  48. )
  49. waitornot = true
  50. elseif not plr.Character:FindFirstChild("PompousTheCloud") then
  51. plr.Backpack:WaitForChild("PompousTheCloud").Parent = plr.Character
  52. end
  53. if waitornot then
  54. wait(1)
  55. end
  56. return coroutine.resume(
  57. coroutine.create(
  58. function()
  59. plr.Character:WaitForChild("PompousTheCloud"):WaitForChild("ServerControl"):InvokeServer(
  60. "SetProperty",
  61. {["Value"] = val, ["Object"] = obj, ["Property"] = prop}
  62. )
  63. end
  64. )
  65. )
  66. end
  67.  
  68. RobloxianLife.InstanceNew = function(slf, classname, props)
  69. local instance = nil
  70.  
  71. if classname == "Part" then
  72. SetRPName("#")
  73. plr.Character:WaitForChild("#")
  74. local part = plr.Character["#"]:WaitForChild("Head")
  75.  
  76. RobloxianLife:SetLocalProperty(part, "Name", "Part")
  77. RobloxianLife:SetLocalProperty(part, "Parent", part.Parent.Parent)
  78. runService.Heartbeat:Wait()
  79. RobloxianLife:SetLocalProperty(plr.Character.Head, "Transparency", 0)
  80. RobloxianLife:SetLocalProperty(plr.Character["#"], "Parent", game.Lighting)
  81. runService.Heartbeat:Wait()
  82.  
  83. instance = part
  84. elseif classname == "Weld" then
  85. GiveTool(GamepassId, "Stroller")
  86. local tool = plr.Backpack:WaitForChild("Stroller")
  87. plr.Character.Humanoid:EquipTool(tool)
  88. local weld = tool.Handle.Weld
  89.  
  90. RobloxianLife:SetLocalProperty(weld, "Parent", weld.Parent.Parent.Parent)
  91. RobloxianLife:SetLocalProperty(tool, "Parent", game.Lighting)
  92.  
  93. instance = weld
  94. elseif classname == "Weld" then
  95. GiveTool(GamepassId, "Stroller")
  96. local tool = plr.Backpack:WaitForChild("Stroller")
  97. plr.Character.Humanoid:EquipTool(tool)
  98. local weld = tool.Handle.Weld
  99.  
  100. RobloxianLife:SetLocalProperty(weld, "Parent", weld.Parent.Parent.Parent)
  101. RobloxianLife:SetLocalProperty(tool, "Parent", game.Lighting)
  102.  
  103. instance = weld
  104. elseif classname == "Sparkles" then
  105. Effect("Sparkles")
  106.  
  107. instance = plr.Character.HumanoidRootPart:WaitForChild("Sparkles")
  108. else
  109. error(string.format("Unsupported classname (%s).", classname))
  110. return
  111. end
  112.  
  113. for i, v in pairs(instance:GetChildren()) do
  114. RobloxianLife:SetLocalProperty(v, "Parent", game.Lighting)
  115. wait(.01)
  116. end
  117.  
  118. local parent = workspace
  119.  
  120. for i, v in pairs(props) do
  121. if tostring(i) == "Parent" then
  122. parent = v
  123. else
  124. RobloxianLife:SetLocalProperty(instance, tostring(i), v)
  125. wait(.01)
  126. end
  127. end
  128.  
  129. RobloxianLife:SetLocalProperty(instance, "Parent", parent)
  130.  
  131. return instance
  132. end
  133.  
  134. return RobloxianLife
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement