Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local plr = game.Players.LocalPlayer
- local plrGui = plr.PlayerGui
- local prefix = ':'
- function getAllTools()
- if plrGui:FindFirstChild('tempGui') then
- plrGui.tempGui:Remove()
- end
- local tempGui = Instance.new('ScreenGui')
- tempGui.Name = 'tempGui'
- tempGui.Parent = plrGui
- local xShift = 0.2
- local yShift = 0.5
- local closeButton = Instance.new('TextButton')
- closeButton.TextColor3 = Color3.new(255, 0, 0)
- closeButton.TextScaled = true
- closeButton.Text = 'X'
- closeButton.Size = UDim2.new(0.05, 0, 0.05, 0)
- closeButton.Position = UDim2.new(0.15, 0, 0.45, 0)
- closeButton.BackgroundColor3 = Color3.new(0, 0, 0)
- closeButton.BackgroundTransparency = 0.5
- closeButton.Parent = tempGui
- closeButton.MouseButton1Click:Connect(function()
- tempGui:Remove()
- end)
- for k, v in pairs(game.Workspace:GetChildren()) do
- if v.ClassName == 'Tool' and v:FindFirstChild('Handle') then
- if xShift >= 0.75 then
- xShift = 0.2
- yShift = yShift + 0.055
- end
- local tempButton = Instance.new('TextButton')
- tempButton.TextColor3 = Color3.new(0, 255, 0)
- tempButton.TextScaled = true
- tempButton.Text = v.Name
- tempButton.Size = UDim2.new(0.15, 0, 0.05, 0)
- tempButton.Position = UDim2.new(xShift, 0, yShift, 0)
- tempButton.BackgroundColor3 = Color3.new(0, 0, 0)
- tempButton.BackgroundTransparency = 0.5
- tempButton.Parent = tempGui
- tempButton.MouseButton1Click:Connect(function()
- if game.Workspace:FindFirstChild(plr.Name) then
- spawn(function()
- v.Handle.CFrame = plr.Character.HumanoidRootPart.CFrame
- tempButton:Remove()
- end)
- end
- end)
- xShift = xShift + 0.155
- end
- end
- end
- local commands = {
- ['gat'] = {
- ['func'] = getAllTools
- }
- }
- plr.Chatted:Connect(function(msg)
- if string.sub(msg, 1, 1) == prefix then
- local raw = string.lower(string.sub(msg, 2))
- local arguments = {}
- for item in string.gmatch(raw, '%w+') do
- table.insert(arguments, item)
- end
- if arguments[1] == nil then
- return
- end
- local command = arguments[1]
- table.remove(arguments, 1)
- if commands[command] ~= nil then
- spawn(commands[command]['func'])
- end
- end
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement