Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local UserInputService = game:GetService("UserInputService")
- local playerGui = game.Players.LocalPlayer:WaitForChild("PlayerGui")
- -- Create ScreenGui
- local screenGui = Instance.new("ScreenGui")
- screenGui.Name = "MyCustomGUI"
- screenGui.ResetOnSpawn = false
- screenGui.Parent = playerGui
- -- Create Frame (do this first!)
- local frame = Instance.new("Frame")
- frame.Size = UDim2.new(0.4, 0, 0.2, 0)
- frame.Position = UDim2.new(0.3, 0, 0.4, 0)
- frame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
- frame.BorderSizePixel = 0
- frame.Parent = screenGui
- -- Draggable logic using the frame
- local dragging = false
- local dragInput
- local dragStart
- local startPos
- local function update(input)
- local delta = input.Position - dragStart
- frame.Position = UDim2.new(
- startPos.X.Scale, startPos.X.Offset + delta.X,
- startPos.Y.Scale, startPos.Y.Offset + delta.Y
- )
- end
- frame.InputBegan:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
- dragging = true
- dragStart = input.Position
- startPos = frame.Position
- input.Changed:Connect(function()
- if input.UserInputState == Enum.UserInputState.End then
- dragging = false
- end
- end)
- end
- end)
- frame.InputChanged:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseMovement or input.UserInputType == Enum.UserInputType.Touch then
- dragInput = input
- end
- end)
- UserInputService.InputChanged:Connect(function(input)
- if input == dragInput and dragging then
- update(input)
- end
- end)
- -- Create credit label first
- local creditLabel = Instance.new("TextLabel")
- creditLabel.Size = UDim2.new(0, 180, 0, 20) -- small width and height
- creditLabel.Position = UDim2.new(0.3, 0, 0.33, 0) -- just above your main frame (which is at 0.4 Y)
- creditLabel.BackgroundTransparency = 1 -- transparent background
- creditLabel.Text = "Credit to COREX HUB OFFICIAL"
- creditLabel.TextColor3 = Color3.fromRGB(200, 200, 200) -- light gray color
- creditLabel.Font = Enum.Font.Gotham
- creditLabel.TextSize = 14
- creditLabel.TextXAlignment = Enum.TextXAlignment.Left
- creditLabel.Parent = screenGui
- -- Then create toggle button and connect event
- local toggleButton = Instance.new("TextButton")
- toggleButton.Size = UDim2.new(0, 100, 0, 30)
- toggleButton.Position = UDim2.new(0, 10, 0, 10) -- top-left corner
- toggleButton.BackgroundColor3 = Color3.fromRGB(50, 50, 50)
- toggleButton.TextColor3 = Color3.fromRGB(255, 255, 255)
- toggleButton.Font = Enum.Font.GothamBold
- toggleButton.TextSize = 18
- toggleButton.Text = "Toggle GUI"
- toggleButton.Parent = screenGui
- toggleButton.MouseButton1Click:Connect(function()
- frame.Visible = not frame.Visible
- creditLabel.Visible = frame.Visible
- end)
- -- Create Button inside the frame
- local button = Instance.new("TextButton")
- button.Size = UDim2.new(1, 0, 1, 0)
- button.Position = UDim2.new(0, 0, 0, 0)
- button.BackgroundColor3 = Color3.fromRGB(25, 25, 25)
- button.TextColor3 = Color3.fromRGB(255, 255, 255)
- button.Font = Enum.Font.GothamBold
- button.TextScaled = true
- button.TextWrapped = true
- button.Text = "Copy Rap 🔥🔥"
- button.Parent = frame
- -- 🔥 Raps List
- local raps = {
- "This dude is short as hell, he went to stages the crowd couldn't even tell.",
- "You are shorter than Kevin Hart, you are shorter than the memory of an old fart.",
- "Now I'm a kind boy, yo face though brought nobody joy.",
- "Everybody know my rhymes are hot, yo short butt could fit in a shoe slot."
- }
- local index = 1 -- Start at rap 1
- button.MouseButton1Click:Connect(function()
- -- Get the current rap
- local rap = raps[index]
- -- ✅ Copy to clipboard (only works in executors like Synapse, Fluxus, etc.)
- setclipboard(rap)
- -- 🔢 Show confirmation
- button.Text = "✅ Copied Rap " .. index .. "/4:\n\"" .. rap .. "\""
- -- ➡ Move to next rap (loop back to 1 after 4)
- index = index + 1
- if index > #raps then
- index = 1
- end
- -- ⏳ Reset text after 3 seconds
- task.delay(3, function()
- button.Text = "Copy Rap 🔥🔥"
- end)
- end)
Advertisement
Add Comment
Please, Sign In to add comment