1 | -- Create a ScreenGui object to hold the GUI elements |
2 | local gui = Instance.new("ScreenGui") |
3 | gui.Name = "ExampleGUI" |
4 | gui.Parent = game.Players.LocalPlayer:WaitForChild("PlayerGui") |
5 | |
6 | -- Create a Frame to hold the GUI elements |
7 | local frame = Instance.new("Frame") |
8 | frame.Size = UDim2.new(0.4, 0, 0.6, 0) -- Size of the frame relative to the screen |
9 | frame.Position = UDim2.new(0.3, 0, 0.2, 0) -- Position of the frame relative to the screen |
10 | frame.BackgroundColor3 = Color3.fromRGB(230, 230, 230) -- Light gray background color |
11 | frame.BorderSizePixel = 0 -- Remove border |
12 | frame.Parent = gui |
13 | |
14 | -- Create a TextLabel for the title |
15 | local title = Instance.new("TextLabel") |
16 | title.Size = UDim2.new(1, 0, 0.1, 0) -- Size of the title relative to the frame |
17 | title.Position = UDim2.new(0, 0, 0, 0) -- Position of the title relative to the frame |
18 | title.Text = "https://discord.gg/pTmc8uEqJr" -- Text to display |
19 | title.TextColor3 = Color3.fromRGB(0, 0, 0) -- Black text color |
20 | title.BackgroundTransparency = 1 -- Make background transparent |
21 | title.Font = Enum.Font.SourceSansBold -- Use bold font |
22 | title.TextSize = 24 -- Text size |
23 | title.Parent = frame |
24 | |
25 | -- Create a TextButton for interaction |
26 | local button = Instance.new("TextButton") |
27 | button.Size = UDim2.new(0.8, 0, 0.1, 0) -- Size of the button relative to the frame |
28 | button.Position = UDim2.new(0.1, 0, 0.3, 0) -- Position of the button relative to the frame |
29 | button.Text = "Click me for some ass leaked!" -- Text on the button |
30 | button.TextColor3 = Color3.fromRGB(255, 255, 255) -- White text color |
31 | button.BackgroundColor3 = Color3.fromRGB(100, 150, 255) -- Blue button color |
32 | button.Font = Enum.Font.SourceSans -- Use default font |
33 | button.TextSize = 20 -- Text size |
34 | button.Parent = frame |
35 | |
36 | -- Function to execute when the button is clicked |
37 | button.MouseButton1Click:Connect(function() |
38 | -- Example action (change the title text) |
39 | title.Text = "NIGGA I SAW YOU HUH WHAT ARE YOU DOING 💀" |
40 | end) |