Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Destroy any previous GUI
- if game.CoreGui:FindFirstChild("GrowAGarden") then
- game.CoreGui.GrowAGarden:Destroy()
- end
- -- Create ScreenGui
- local gui = Instance.new("ScreenGui")
- gui.Name = "GrowAGarden"
- gui.ResetOnSpawn = false
- gui.Parent = game.CoreGui
- -- Create Main Frame
- local Frame = Instance.new("Frame")
- Frame.Size = UDim2.new(0, 400, 0, 300)
- Frame.Position = UDim2.new(0.5, -200, 0.5, -150)
- Frame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
- Frame.Active = true
- Frame.Draggable = true
- Frame.Parent = gui
- local frameCorner = Instance.new("UICorner", Frame)
- frameCorner.CornerRadius = UDim.new(0, 12)
- -- Header Label
- local TextLabel = Instance.new("TextLabel")
- TextLabel.Size = UDim2.new(1, 0, 0, 40)
- TextLabel.BackgroundColor3 = Color3.fromRGB(60, 60, 60)
- TextLabel.Text = "Grow A Garden"
- TextLabel.TextColor3 = Color3.fromRGB(255, 255, 255)
- TextLabel.Font = Enum.Font.GothamBold
- TextLabel.TextSize = 20
- TextLabel.Parent = Frame
- local labelCorner = Instance.new("UICorner", TextLabel)
- labelCorner.CornerRadius = UDim.new(0, 12)
- -- Keybind Toggle (RightControl)
- local guiVisible = true
- game:GetService("UserInputService").InputBegan:Connect(function(input, gameProcessed)
- if gameProcessed then return end
- if input.KeyCode == Enum.KeyCode.RightControl then
- guiVisible = not guiVisible
- gui.Enabled = guiVisible
- end
- end)
- -- Tabs Frame
- local TabsFrame = Instance.new("Frame")
- TabsFrame.Size = UDim2.new(0, 100, 1, -40)
- TabsFrame.Position = UDim2.new(0, 0, 0, 40)
- TabsFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
- TabsFrame.Parent = Frame
- local tabsCorner = Instance.new("UICorner", TabsFrame)
- tabsCorner.CornerRadius = UDim.new(0, 12)
- -- Tab Buttons
- local mainTabButton = Instance.new("TextButton")
- mainTabButton.Size = UDim2.new(1, 0, 0, 30)
- mainTabButton.Position = UDim2.new(0, 0, 0, 10)
- mainTabButton.BackgroundColor3 = Color3.fromRGB(60, 60, 60)
- mainTabButton.Text = "Main"
- mainTabButton.TextColor3 = Color3.fromRGB(255, 255, 255)
- mainTabButton.Font = Enum.Font.Gotham
- mainTabButton.TextSize = 14
- mainTabButton.Parent = TabsFrame
- Instance.new("UICorner", mainTabButton).CornerRadius = UDim.new(0, 12)
- local miscTabButton = mainTabButton:Clone()
- miscTabButton.Text = "Misc"
- miscTabButton.Position = UDim2.new(0, 0, 0, 50)
- miscTabButton.Parent = TabsFrame
- -- Main Tab Content
- local MainFrame = Instance.new("Frame")
- MainFrame.Size = UDim2.new(1, -110, 1, -50)
- MainFrame.Position = UDim2.new(0, 110, 0, 50)
- MainFrame.BackgroundColor3 = Color3.fromRGB(50, 50, 50)
- MainFrame.Visible = true
- MainFrame.Parent = Frame
- Instance.new("UICorner", MainFrame).CornerRadius = UDim.new(0, 12)
- -- Scrollable List inside Main Tab
- local ScrollingFrameMain = Instance.new("ScrollingFrame")
- ScrollingFrameMain.Size = UDim2.new(1, -10, 1, -10)
- ScrollingFrameMain.Position = UDim2.new(0, 5, 0, 5)
- ScrollingFrameMain.CanvasSize = UDim2.new(0, 0, 0, 0)
- ScrollingFrameMain.ScrollBarThickness = 6
- ScrollingFrameMain.BackgroundTransparency = 1
- ScrollingFrameMain.Parent = MainFrame
- Instance.new("UICorner", ScrollingFrameMain).CornerRadius = UDim.new(0, 12)
- -- Layout for scroll content
- local layout = Instance.new("UIListLayout", ScrollingFrameMain)
- layout.Padding = UDim.new(0, 6)
- layout.SortOrder = Enum.SortOrder.LayoutOrder
- -- TP Tool Button (only in Main tab)
- local tpButton = Instance.new("TextButton")
- tpButton.Size = UDim2.new(1, -10, 0, 40)
- tpButton.BackgroundColor3 = Color3.fromRGB(100, 100, 100)
- tpButton.Text = "TP Tool"
- tpButton.TextColor3 = Color3.fromRGB(255, 255, 255)
- tpButton.Font = Enum.Font.Gotham
- tpButton.TextSize = 16
- tpButton.Parent = ScrollingFrameMain
- Instance.new("UICorner", tpButton).CornerRadius = UDim.new(0, 12)
- tpButton.MouseButton1Click:Connect(function()
- -- Remove existing TP Tool if present
- local backpack = game.Players.LocalPlayer:FindFirstChild("Backpack")
- if backpack then
- local existingTool = backpack:FindFirstChild("TP Tool")
- if existingTool then
- existingTool:Destroy()
- end
- end
- -- Create new TP Tool
- local tool = Instance.new("Tool")
- tool.Name = "TP Tool"
- tool.RequiresHandle = false
- -- Define the teleportation behavior
- tool.Activated:Connect(function()
- local player = game.Players.LocalPlayer
- local mouse = player:GetMouse()
- local targetPosition = mouse.Hit + Vector3.new(0, 2.5, 0)
- player.Character.HumanoidRootPart.CFrame = CFrame.new(targetPosition.X, targetPosition.Y, targetPosition.Z)
- end)
- -- Add the tool to the player's backpack
- tool.Parent = backpack
- end)
- -- Misc Tab Content (clean)
- local MiscFrame = Instance.new("Frame")
- MiscFrame.Size = UDim2.new(1, -110, 1, -50)
- MiscFrame.Position = UDim2.new(0, 110, 0, 50)
- MiscFrame.BackgroundColor3 = Color3.fromRGB(50, 50, 50)
- MiscFrame.Visible = false
- MiscFrame.Parent = Frame
- Instance.new("UICorner", MiscFrame).CornerRadius = UDim.new(0, 12)
- -- Tab switching logic
- mainTabButton.MouseButton1Click:Connect(function()
- MainFrame.Visible = true
- MiscFrame.Visible = false
- end)
- miscTabButton.MouseButton1Click:Connect(function()
- MainFrame.Visible = false
- MiscFrame.Visible = true
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement