Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function randomName()
- local data = ""
- for i=0,20,1 do
- data = data .. tostring(string.char(math.ceil(math.random() * 254)))
- end
- return data
- end
- local DaUiLib = Instance.new("ScreenGui")
- DaUiLib.Name = randomName()
- DaUiLib.Parent = game:GetService("CoreGui")
- DaUiLib.ZIndexBehavior = Enum.ZIndexBehavior.Sibling
- local library = {}
- local TweenService = game:GetService("TweenService")
- local uis = game:GetService("UserInputService")
- local tabcount = 0
- local rainbow = 0
- _G.breatherate = 0.005
- local color
- local rainbows = {}
- local buttoncount = {}
- function library:CreateTab(name)
- tabcount = tabcount+1
- buttoncount[tabcount] = 0
- local topbar = Instance.new("Frame")
- local rgbbar = Instance.new("Frame")
- local title = Instance.new("TextLabel")
- local OpenClose = Instance.new("TextButton")
- local container = Instance.new("Frame")
- local UIListLayout = Instance.new("UIListLayout")
- topbar.Name = "topbar"
- topbar.Parent = DaUiLib
- topbar.BackgroundColor3 = Color3.fromRGB(30, 30, 30)
- topbar.BorderSizePixel = 0
- topbar.Position = UDim2.new(0, (tabcount)*13+(tabcount-1)*200, 0.0128041022, -500)
- wait(0.3)
- topbar:TweenPosition(UDim2.new(0, (tabcount)*13+(tabcount-1)*200, 0.0128041022, 0))
- topbar.Size = UDim2.new(0, 200, 0, 30)
- rgbbar.Name = "rgbbar"
- rgbbar.Parent = topbar
- rgbbar.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
- rgbbar.BorderSizePixel = 0
- rgbbar.Position = UDim2.new(0, 0, 1, -3)
- rgbbar.Size = UDim2.new(1, 0, 0, 3)
- title.Name = "title"
- title.Parent = topbar
- title.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
- title.BackgroundTransparency = 1.000
- title.BorderSizePixel = 0
- title.Position = UDim2.new(0, 5, 0, 0)
- title.Size = UDim2.new(1, -40, 1, 0)
- title.Font = Enum.Font.GothamBold
- title.Text = name
- title.TextColor3 = Color3.fromRGB(255, 255, 255)
- title.TextSize = 16.000
- title.TextXAlignment = Enum.TextXAlignment.Left
- OpenClose.Name = "OpenClose"
- OpenClose.Parent = topbar
- OpenClose.BackgroundColor3 = Color3.fromRGB(255, 255, 255)
- OpenClose.BackgroundTransparency = 1.000
- OpenClose.Position = UDim2.new(0.861656487, 0, 0.0666666701, 0)
- OpenClose.Size = UDim2.new(0, 27, 0, 25)
- OpenClose.Font = Enum.Font.GothamBold
- OpenClose.Text = "+"
- OpenClose.TextColor3 = Color3.fromRGB(255, 255, 255)
- OpenClose.TextSize = 20.000
- container.Name = "container"
- container.Parent = topbar
- container.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
- container.BackgroundTransparency = 1.000
- container.BorderSizePixel = 0
- container.Position = UDim2.new(0, 2, 1, 0)
- container.Size = UDim2.new(1, -4, 0, 0)
- container.Visible = true
- UIListLayout.Parent = container
- UIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
- local uis = game:GetService("UserInputService")
- local dragthing = topbar
- dragthing.Active = true
- local dragging
- local draginput
- local dragstart
- local startpos
- local function update(input)
- local delta = input.Position - dragstart
- game:GetService("TweenService"):Create(dragthing, TweenInfo.new(.15), {Position = UDim2.new(startpos.X.Scale, startpos.X.Offset + delta.X, startpos.Y.Scale, startpos.Y.Offset + delta.Y)}):Play()
- end
- dragthing.InputBegan:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseButton1 then
- dragging = true
- dragstart = input.Position
- startpos = dragthing.Position
- input.Changed:Connect(function()
- if input.UserInputState == Enum.UserInputState.End then
- dragging = false
- end
- end)
- end
- end)
- dragthing.InputChanged:Connect(function(input)
- if input.UserInputType == Enum.UserInputType.MouseMovement then
- draginput = input
- end
- end)
- uis.InputChanged:Connect(function(input)
- if input == draginput and dragging then
- update(input)
- end
- end)
- local enabled = false
- OpenClose.MouseButton1Click:Connect(function()
- if enabled == false then
- enabled = true
- container:TweenSize(UDim2.new(1, -4, 0, 175), Enum.EasingDirection.In, Enum.EasingStyle.Sine, 0.3,true);
- wait(0.3)
- OpenClose.Text = "-"
- elseif enabled == true then
- enabled = false
- container:TweenSize(UDim2.new(1, -4, 0, 0), Enum.EasingDirection.In, Enum.EasingStyle.Sine, 0.3,true);
- wait(0.3)
- OpenClose.Text = "+"
- end
- end)
- local GamerLibrary = {}
- function GamerLibrary:CreateButton(name,func)
- local ButtonFrame = Instance.new("Frame")
- local Button = Instance.new("TextButton")
- ButtonFrame.Name = "ButtonFrame"
- ButtonFrame.Parent = container
- ButtonFrame.BackgroundColor3 = Color3.fromRGB(40, 40, 40)
- ButtonFrame.BorderColor3 = Color3.fromRGB(27, 42, 53)
- ButtonFrame.BorderSizePixel = 0
- ButtonFrame.Size = UDim2.new(0, 196, 0, 25)
- Button.Name = "Button"
- Button.Parent = ButtonFrame
- Button.BackgroundColor3 = Color3.fromRGB(21, 21, 21)
- Button.BorderSizePixel = 0
- Button.Position = UDim2.new(0.0430000164, 0, 0.170000002, 0)
- Button.Size = UDim2.new(0, 180, 0, 18)
- Button.Font = Enum.Font.GothamBold
- Button.TextColor3 = Color3.fromRGB(255, 255, 255)
- Button.TextSize = 12.000
- Button.TextWrapped = true
- Button.Text = name
- Button.MouseButton1Click:Connect(func);
- end
- return GamerLibrary;
- end
- return library;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement