axelloft1

Bruh

Jul 4th, 2020
1,539
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.76 KB | None | 0 0
  1. -- KEY
  2. local Key = Enum.KeyCode.LeftControl
  3. -- By axelloft1 pls dont skid
  4. local Plr = game:GetService("Players").LocalPlayer
  5. local Mouse = Plr:GetMouse()
  6.  
  7. local CtrlZ = {}
  8. local Object = nil
  9. Mouse.Button1Down:connect(function()
  10. if not game:GetService("UserInputService"):IsKeyDown(Key) then return end
  11. if not Mouse.Target then return end
  12. Object = Mouse.Target
  13. Object.Parent = game.ReplicatedStorage
  14. table.insert(CtrlZ,#CtrlZ + 1,Object)
  15. end)
  16.  
  17. game:GetService("UserInputService").InputBegan:Connect(function()
  18. if not game:GetService("UserInputService"):IsKeyDown(Key) then return end
  19. if not game:GetService("UserInputService"):IsKeyDown(Enum.KeyCode.Z) then return end
  20. local Bruh = CtrlZ[#CtrlZ]
  21. Bruh.Parent = game.Workspace
  22. table.remove(CtrlZ,#CtrlZ)
  23. end)
Advertisement
Add Comment
Please, Sign In to add comment