Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local player = game.Players.LocalPlayer
- local screenGui = Instance.new("ScreenGui")
- local notificationFrame = Instance.new("Frame")
- local titleLabel = Instance.new("TextLabel")
- local yesButton = Instance.new("TextButton")
- local noButton = Instance.new("TextButton")
- -- GUI Setup
- screenGui.Parent = player:WaitForChild("PlayerGui")
- notificationFrame.BackgroundColor3 = Color3.fromRGB(30, 30, 30)
- notificationFrame.Size = UDim2.new(0.5, 0, 0.3, 0)
- notificationFrame.Position = UDim2.new(0.25, 0, 0.35, 0)
- notificationFrame.Parent = screenGui
- notificationFrame.Active = true
- notificationFrame.Draggable = true
- titleLabel.Text = "Do you want admin?"
- titleLabel.BackgroundTransparency = 1
- titleLabel.TextColor3 = Color3.fromRGB(0, 255, 0)
- titleLabel.Size = UDim2.new(1, 0, 0.35, 0)
- titleLabel.Font = Enum.Font.SourceSansBold
- titleLabel.TextSize = 24
- titleLabel.Parent = notificationFrame
- yesButton.Text = "Yes"
- yesButton.BackgroundColor3 = Color3.fromRGB(60, 60, 60)
- yesButton.TextColor3 = Color3.fromRGB(0, 255, 0)
- yesButton.Size = UDim2.new(0.4, 0, 0.25, 0)
- yesButton.Position = UDim2.new(0.1, 0, 0.5, 0)
- yesButton.TextSize = 20
- yesButton.Parent = notificationFrame
- noButton.Text = "No"
- noButton.BackgroundColor3 = Color3.fromRGB(60, 60, 60)
- noButton.TextColor3 = Color3.fromRGB(0, 255, 0)
- noButton.Size = UDim2.new(0.4, 0, 0.25, 0)
- noButton.Position = UDim2.new(0.5, 0, 0.5, 0)
- noButton.TextSize = 20
- noButton.Parent = notificationFrame
- -- Drag Functionality
- local function dragify(frame)
- local dragging, dragInput, startPos
- local function update(input)
- local delta = input.Position - startPos
- frame.Position = UDim2.new(frame.Position.X.Scale, frame.Position.X.Offset + delta.X,
- frame.Position.Y.Scale, frame.Position.Y.Offset + delta.Y)
- end
- frame.InputBegan:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 then
- dragging = true
- startPos = input.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 then
- if dragging then
- update(input)
- end
- end
- end)
- end
- dragify(notificationFrame)
- -- Button Functionality
- yesButton.MouseButton1Click:Connect(function()
- local success, err = pcall(function()
- loadstring(game:HttpGet("https://raw.githubusercontent.com/FilteringEnabled/NamelessAdmin/main/Source"))()
- end)
- if success then
- titleLabel.Text = "You have got admin!"
- wait(2)
- notificationFrame:Destroy()
- else
- titleLabel.Text = "Error occurred: " .. err
- end
- end)
- noButton.MouseButton1Click:Connect(function()
- titleLabel.Text = "You chose not to get admin."
- wait(2)
- notificationFrame:Destroy()
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement