draxe55

piggyscript

May 24th, 2021
168
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.10 KB | None | 0 0
  1. [DO NOT COPY THIS PART]
  2. -- [[
  3. ██████╗░██╗░░░██╗██████╗░███████╗  ███████╗██╗░░██╗██████╗░██╗░░░░░░█████╗░████████╗░██████╗
  4. ██╔══██╗██║░░░██║██╔══██╗██╔════╝  ██╔════╝╚██╗██╔╝██╔══██╗██║░░░░░██╔══██╗╚══██╔══╝██╔════╝
  5. ██║░░██║██║░░░██║██║░░██║█████╗░░  █████╗░░░╚███╔╝░██████╔╝██║░░░░░██║░░██║░░░██║░░░╚█████╗░
  6. ██║░░██║██║░░░██║██║░░██║██╔══╝░░  ██╔══╝░░░██╔██╗░██╔═══╝░██║░░░░░██║░░██║░░░██║░░░░╚═══██╗
  7. ██████╔╝╚██████╔╝██████╔╝███████╗  ███████╗██╔╝╚██╗██║░░░░░███████╗╚█████╔╝░░░██║░░░██████╔╝
  8. ╚═════╝░░╚═════╝░╚═════╝░╚══════╝  ╚══════╝╚═╝░░╚═╝╚═╝░░░░░╚══════╝░╚════╝░░░░╚═╝░░░╚═════╝░
  9. -- ]]
  10.  
  11.  
  12. (COPY THE TEXT UNDER ME)
  13.  
  14. repeat
  15. wait()
  16. until game:IsLoaded()
  17. local PiggyGui = Instance.new("ScreenGui")
  18. PiggyGui.Name = "PiggyGui"
  19. PiggyGui.Parent = game.StarterGui
  20.  
  21. local ScrollingFrame = Instance.new("ScrollingFrame", PiggyGui)
  22. ScrollingFrame.BackgroundColor3 = Color3.new(0.15, 0.15, 0.15)
  23. ScrollingFrame.Position = UDim2.new(0.08, 0, 0.42, 0)
  24. ScrollingFrame.Size = UDim2.new(0, 296, 0, 388)
  25.  
  26.  
  27.  
  28.  
  29. local PiggyGui = Instance.new("ScreenGui")
  30. PiggyGui.Name = "PiggyGui"
  31. PiggyGui.Parent = game.CoreGui
  32.  
  33. local ScrollingFrame = Instance.new("ScrollingFrame", PiggyGui)
  34. ScrollingFrame.BackgroundColor3 = Color3.new(0.15, 0.15, 0.15)
  35. ScrollingFrame.Position = UDim2.new(0.08, 0, 0.42, 0)
  36. ScrollingFrame.Size = UDim2.new(0, 296, 0, 388)
  37.  
  38. local UIGridLayout = Instance.new("UIGridLayout", ScrollingFrame)
  39. UIGridLayout.CellSize = UDim2.new(0,90,0,90)
  40.  
  41. while wait(1) do
  42. local a = workspace:getDescendants()
  43. local items = {}
  44. local itemframes = ScrollingFrame:getChildren()
  45. for i=1,#itemframes do
  46. if itemframes[i].ClassName == "TextButton" then
  47. itemframes[i]:remove()
  48. end
  49. end
  50. for i=1,#a do
  51. if a[i].Name == "ItemPickupScript" and a[i].Parent:findFirstChild("ClickDetector") then
  52. table.insert(items, a[i].Parent)
  53. end
  54. end
  55. for i=1,#items do
  56. local ItemFrame = Instance.new("TextButton", ScrollingFrame)
  57. ItemFrame.Name = "ItemFrame"
  58. ItemFrame.BackgroundColor3 = Color3.new(1, 1, 1)
  59. ItemFrame.BackgroundTransparency = 0.95
  60. ItemFrame.Size = UDim2.new(0, 100, 0, 100)
  61. ItemFrame.Text = ""
  62. local View = Instance.new("ViewportFrame", ItemFrame)
  63. View.Name = "View"
  64. View.Size = UDim2.new(1,0,1,0)
  65. View.BackgroundTransparency = 1
  66. View.BorderSizePixel = 0
  67. local object = items[i]
  68. local viewportclone = object:Clone()
  69. viewportclone.Parent = View
  70. local cam = Instance.new("Camera", viewportclone)
  71. cam.CameraType = Enum.CameraType.Fixed
  72. local objectPosition = object.Position
  73. local cameraPosition = objectPosition + Vector3.new(0,3,0)
  74. cam.CoordinateFrame = CFrame.new(cameraPosition, objectPosition)
  75. View.CurrentCamera = cam
  76.  
  77. ItemFrame.MouseButton1Down:connect(function()
  78. if items[i]:findFirstChild("ClickDetector") then
  79. local cpos = game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame
  80. wait(0.05)
  81. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = items[i].CFrame
  82. wait(0.1)
  83. fireclickdetector(items[i].ClickDetector)
  84. wait(0.3)
  85. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = cpos
  86. end
  87. end)
  88. end
  89. end
  90.  
Advertisement
Add Comment
Please, Sign In to add comment