Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local lib;lib = setmetatable({
- LocalPlayer = game:GetService("Players").LocalPlayer,
- Mouse = game:GetService("Players").LocalPlayer:GetMouse(),
- },{
- __index = function(self,index)
- return index == "Init" and function(self)
- if not self.GUI then
- self.GUI = Instance.new("ScreenGui",game.CoreGui)
- else
- self:DP("UnNeeded Init request.")
- end
- end or index == "CreateFrame" and function(self,properties)
- local frame = {
- Instance = Instance.new("TextButton",self.GUI),
- ViewFrames = {},
- Row = 1,
- ButtonOffset = -4,
- }
- self:MakeMoveable(frame.Instance)
- local UICorner = Instance.new("UICorner",frame.Instance)
- local UIPadding = Instance.new("UIPadding",frame.Instance)
- frame.Instance.Name = "Frame"
- frame.Instance.BackgroundColor3 = Color3.new(0.054902, 0.054902, 0.0784314)
- frame.Instance.Position = UDim2.new(0.5, 0, 0.5, 0)
- frame.Instance.AutoButtonColor = false
- frame.Instance.Font = Enum.Font.ArialBold
- frame.Instance.LineHeight = 1
- frame.Instance.TextColor3 = Color3.new(0.0627451, 0.0627451, 0.0941177)
- frame.Instance.TextSize = 45
- UICorner.CornerRadius = UDim.new(0, 4)
- UIPadding.PaddingBottom = UDim.new(0, 10)
- UIPadding.PaddingLeft = UDim.new(0, 10)
- UIPadding.PaddingRight = UDim.new(0, 10)
- UIPadding.PaddingTop = UDim.new(0, 10)
- frame.Instance.Size = properties.Size == "Small" and UDim2.new() or properties.Size == "Medium" and UDim2.new(0,648,0,348) or properties.Size == "Large" and UDim2.new()
- frame.Instance.Text = properties.GUIName
- return setmetatable(frame,{
- __index = function(self,index)
- return index == "CreateButton" and function(self,properties)
- local button = {}
- button.Instance = Instance.new("TextButton",self.Instance)
- button.Action = nil
- button.Locked = false
- local UICorner = Instance.new("UICorner",button.Instance)
- UICorner.CornerRadius = UDim.new(0,4)
- button.Instance.Name = properties.Name
- button.Instance.BackgroundColor3 = Color3.fromRGB(14, 14, 20)
- button.Instance.BorderSizePixel = 0
- button.Instance.Position = UDim2.new(0, self.ButtonOffset, 0, -30)
- button.Instance.Text = properties.Name
- button.Instance.Size = UDim2.new(0,button.Instance.TextBounds.x+47, 0, 25)
- button.Instance.AutoButtonColor = false
- button.Instance.Font = Enum.Font.SourceSansSemibold
- button.Instance.TextColor3 = Color3.new(1, 1, 1)
- button.Instance.TextSize = 16
- self.ButtonOffset+=8+button.Instance.Size.X.Offset
- if properties.Image then
- end
- button.Instance.MouseButton1Click:Connect(function()
- if button.Action and not button.Locked then
- if button.Action.Instance:IsA("Frame") then
- self:CloseViewFrames()
- button.Action.Instance.Visible = not button.Action.Instance.Visible
- game:GetService("TweenService"):Create(button.Instance,TweenInfo.new(.12),{BackgroundColor3=Color3.fromRGB(19,19,27)}):Play()
- elseif button.Action:IsA("SOME OTHER SHIT HERE") then
- end
- elseif not button.Locked then
- lib:DP("Button not linked.")
- end
- end)
- return setmetatable(button,{
- __index = function(self,index)
- return index == "Link" and function(self,linkframe)
- if not self.Action then
- self.Action = linkframe
- frame.ViewFrames[linkframe]["LinkedButton"] = self
- else
- lib:DP("Button already linked.")
- end
- end or index == "Lock" and function(self,set)
- set = not set
- self.Locked = set
- if set then
- if self.Action then
- frame.ViewFrames[self.Action]["LinkedButton"] = nil
- end
- self.Instance.BackgroundColor3 = Color3.fromRGB(10, 10, 16)
- end
- end
- end,
- })
- end or index == "CreateViewFrame" and function(self,properties)
- local viewframe = {}
- viewframe.Instance = Instance.new("Frame",self.Instance)
- viewframe.Instance.Size = (properties.Size == "Half" and UDim2.new(.5,-5,1,0)) or UDim2.new(1,0,1,0)
- viewframe.Instance.Visible = false
- viewframe.Instance.BackgroundTransparency = 1
- self.ViewFrames[viewframe] = {LinkedButton = nil,}
- return setmetatable(viewframe,{
- __index = function(self,index)
- return index == "CreateToggleButton" and function(self,properties)
- local button = {}
- button.Instance = Instance.new("TextButton",self.Instance)
- button.Instance.Position = properties.Position
- local SliderView = Instance.new("Frame",button.Instance)
- local Slider = Instance.new("Frame",SliderView)
- local Handle = Instance.new("TextLabel",Slider)
- local NameText = Instance.new("TextLabel",button.Instance)
- local UICorner = Instance.new("UICorner",button.Instance)
- UICorner.CornerRadius = UDim.new(0,4)
- UICorner:Clone().Parent = SliderView
- UICorner:Clone().Parent = Slider
- UICorner.CornerRadius = UDim.new(0,2)
- UICorner:Clone().Parent = Handle
- UICorner.CornerRadius = UDim.new(0,4)
- button.Instance.Name = "TempToggle"
- button.Instance.BackgroundColor3 = Color3.new(0.0745098, 0.0745098, 0.105882)
- button.Instance.Size = UDim2.new(0, 150, 0, 37)
- button.Instance.AutoButtonColor = false
- button.Instance.Font = Enum.Font.SourceSans
- button.Instance.Text = ""
- button.Instance.TextColor3 = Color3.new(0, 0, 0)
- button.Instance.TextSize = 14
- SliderView.Name = "SliderView"
- SliderView.AnchorPoint = Vector2.new(0.5, 0.5)
- SliderView.BackgroundColor3 = Color3.new(1, 1, 1)
- SliderView.BorderSizePixel = 0
- SliderView.Position = UDim2.new(0.5, 0, 1, -11)
- SliderView.Size = UDim2.new(1, -18, 0, 8)
- Slider.Name = "Slider"
- Slider.BackgroundColor3 = Color3.new(0.596078, 0.945098, 0.584314)
- Slider.BorderSizePixel = 0
- Handle.Name = "Handle"
- Handle.Parent = Slider
- Handle.AnchorPoint = Vector2.new(0.5, 0.5)
- Handle.BackgroundColor3 = Color3.new(0.886275, 0.929412, 1)
- Handle.Position = UDim2.new(1, 0, 0.5, 0)
- Handle.Size = UDim2.new(0, 8, 1, 6)
- Handle.Font = Enum.Font.SourceSans
- Handle.Text = ""
- Handle.TextColor3 = Color3.new(0, 0, 0)
- Handle.TextSize = 14
- NameText.Name = "NameText"
- NameText.Parent = button.Instance
- NameText.BackgroundColor3 = Color3.new(1, 1, 1)
- NameText.BackgroundTransparency = 1
- NameText.BorderSizePixel = 0
- NameText.Size = UDim2.new(1, 0, 0, 20)
- NameText.Font = Enum.Font.ArialBold
- NameText.Text = " silentaim"
- NameText.TextColor3 = Color3.new(1, 1, 1)
- NameText.TextSize = 14
- NameText.TextXAlignment = Enum.TextXAlignment.Left
- button.Name = ""
- button.Activated = false
- button.Instance.NameText.Text = " "..button.Name
- button.Instance.SliderView.Slider.Size = button.Activated and UDim2.new(1,0,1,0) or UDim2.new(0,0,1,0)
- button.Instance.SliderView.Slider.BackgroundColor3 = button.Activated and Color3.fromRGB(152, 241, 149) or Color3.fromRGB(226, 237, 255)
- button.Instance.MouseButton1Click:Connect(function()
- button.Activated = not button.Activated
- if button.OnUpdate then
- button:OnUpdate()
- end
- game:GetService("TweenService"):Create(button.Instance.SliderView.Slider,TweenInfo.new(.12),{Size = button.Activated and UDim2.new(1,0,1,0) or UDim2.new(0,0,1,0),BackgroundColor3 = button.Activated and Color3.fromRGB(152, 241, 149) or Color3.fromRGB(226, 237, 255)}):Play()
- end)
- return setmetatable(button,{
- __index = function(self,index)
- return index == "Update" and function(self)
- self.Instance.SliderView.Slider.Size = self.Activated and UDim2.new(1,0,1,0) or UDim2.new(0,0,1,0)
- self.Instance.SliderView.Slider.BackgroundColor3 = self.Activated and Color3.fromRGB(152, 241, 149) or Color3.fromRGB(226, 237, 255)
- self.Instance.NameText.Text = " "..self.Name
- end
- end,
- })
- end or index == "CreateSlider" and function(self,properties)
- local slider = {}
- slider.Instance = Instance.new("Frame",self.Instance)
- slider.Instance.Position = properties.Position
- local SliderView = Instance.new("Frame",slider.Instance)
- local Slider = Instance.new("Frame",SliderView)
- local DragButton = Instance.new("TextButton",Slider)
- local NameText = Instance.new("TextLabel",slider.Instance)
- local ProcentText = Instance.new("TextLabel",slider.Instance)
- local UICorner = Instance.new("UICorner",slider.Instance)
- UICorner.CornerRadius = UDim.new(0,4)
- UICorner:Clone().Parent = SliderView
- UICorner:Clone().Parent = Slider
- UICorner.CornerRadius = UDim.new(0,2)
- UICorner:Clone().Parent = DragButton
- UICorner.CornerRadius = UDim.new(0,4)
- slider.Instance.Name = "TempSlider"
- slider.Instance.BackgroundColor3 = Color3.new(0.0745098, 0.0745098, 0.105882)
- slider.Instance.Size = UDim2.new(0, 150, 0, 37)
- SliderView.Name = "SliderView"
- SliderView.AnchorPoint = Vector2.new(0.5, 0.5)
- SliderView.BackgroundColor3 = Color3.new(1, 1, 1)
- SliderView.BorderSizePixel = 0
- SliderView.Position = UDim2.new(0.5, 0, 1, -11)
- SliderView.Size = UDim2.new(1, -18, 0, 8)
- Slider.Name = "Slider"
- Slider.BackgroundColor3 = Color3.new(1, 0.803922, 0)
- Slider.BorderSizePixel = 0
- Slider.Size = UDim2.new(0.5, 0, 1, 0)
- DragButton.Name = "DragButton"
- DragButton.AnchorPoint = Vector2.new(0.5, 0.5)
- DragButton.BackgroundColor3 = Color3.new(0.886275, 0.929412, 1)
- DragButton.BorderSizePixel = 0
- DragButton.Position = UDim2.new(1, 0, 0.5, 0)
- DragButton.Size = UDim2.new(0, 8, 1, 6)
- DragButton.AutoButtonColor = false
- DragButton.Font = Enum.Font.SourceSans
- DragButton.Text = ""
- DragButton.TextColor3 = Color3.new(0, 0, 0)
- DragButton.TextSize = 14
- NameText.Name = "NameText"
- NameText.BackgroundColor3 = Color3.new(1, 1, 1)
- NameText.BackgroundTransparency = 1
- NameText.BorderSizePixel = 0
- NameText.Size = UDim2.new(1, 0, 0, 20)
- NameText.Font = Enum.Font.ArialBold
- NameText.TextColor3 = Color3.new(1, 1, 1)
- NameText.TextSize = 14
- NameText.TextXAlignment = Enum.TextXAlignment.Left
- ProcentText.Name = "ProcentText"
- ProcentText.BackgroundColor3 = Color3.new(1, 1, 1)
- ProcentText.BackgroundTransparency = 1
- ProcentText.BorderSizePixel = 0
- ProcentText.Size = UDim2.new(1, 0, 0, 20)
- ProcentText.Font = Enum.Font.ArialBold
- ProcentText.TextColor3 = Color3.fromRGB(26, 26, 30)
- ProcentText.TextSize = 12
- ProcentText.TextXAlignment = Enum.TextXAlignment.Right
- slider.Procent = 0
- slider.Name = ""
- slider.MaxProcent = 100
- slider.Active = false
- slider.Instance.SliderView.Slider.Size = UDim2.new(slider.Procent/slider.MaxProcent,0,1,0)
- slider.Instance.ProcentText.Text = slider.Procent/slider.MaxProcent.." "
- slider.Instance.NameText.Text = " "..slider.Name
- slider.Instance.SliderView.Slider.DragButton.MouseButton1Down:Connect(function()
- slider.Active = true
- repeat game:GetService("RunService").RenderStepped:Wait()
- slider.Procent = slider.MaxProcent*((lib.Mouse.x-slider.Instance.SliderView.AbsolutePosition.x)/slider.Instance.SliderView.AbsoluteSize.x)
- slider.Procent = slider.Procent < 0 and 0 or slider.Procent > slider.MaxProcent and slider.MaxProcent or slider.Procent
- slider:Update()
- until not slider.Active
- end)
- slider.Instance.SliderView.Slider.DragButton.MouseButton1Up:Connect(function()
- slider.Active = false
- end)
- return setmetatable(slider,{
- __index = function(self,index)
- return index == "Update" and function(self)
- local XProcent = slider.Procent/slider.MaxProcent
- XProcent = not slider.Active and XProcent < .1 and .1 or XProcent
- game:GetService("TweenService"):Create(slider.Instance.SliderView.Slider,TweenInfo.new(.06),{Size=UDim2.new(XProcent,0,1,0)}):Play()
- slider.Instance.ProcentText.Text = math.floor(slider.Procent).." "
- slider.Instance.NameText.Text = " "..slider.Name
- if slider.OnUpdate then
- slider:OnUpdate()
- end
- end
- end,
- })
- end or index == "CreateInfoLabel" and function(self,properties)
- local label = {}
- label.Instance = nil
- label.Instance.Position = properties.Position
- label.Name = ""
- label.Text = ""
- label.Instance.Text = " "..label.Text
- label.Instance.NameText = " "..label.Name
- return setmetatable(label,{
- __index = function(self,index)
- return index == "Update" and function(self)
- self.Instance.Text = " "..self.Text
- self.Instance.NameText = " "..self.Name
- end
- end,
- })
- end or index == "CreateDropdown" and function(self,properties)
- local dropdown = {}
- dropdown.Instance = Instance.new("Frame",self.Instance)
- dropdown.Instance.Position = properties.Position
- dropdown.Items = {}
- dropdown.Selected = "n/a"
- local OpenButton = Instance.new("TextButton",dropdown.Instance)
- local MenuFrame = Instance.new("Frame",OpenButton)
- local Menu = Instance.new("Frame",MenuFrame)
- local UIPadding = Instance.new("UIPadding",Menu)
- local UIListLayout = Instance.new("UIListLayout",Menu)
- local Option = Instance.new("TextButton")
- local OptionName = Instance.new("TextLabel",Option)
- local NameText = Instance.new("TextLabel",dropdown.Instance)
- local SelectedItem = Instance.new("TextLabel",dropdown.Instance)
- local UICorner = Instance.new("UICorner",dropdown.Instance)
- UICorner.CornerRadius = UDim.new(0,4)
- dropdown.Instance.Name = "TempDropdown"
- dropdown.Instance.BackgroundColor3 = Color3.new(0.0745098, 0.0745098, 0.105882)
- dropdown.Instance.Size = UDim2.new(0, 100, 0, 54)
- dropdown.Instance.SizeConstraint = Enum.SizeConstraint.RelativeXX
- UICorner:Clone().Parent = OpenButton
- UICorner:Clone().Parent = Menu
- UICorner:Clone().Parent = Option
- UICorner:Clone().Parent = OptionName
- UICorner:Clone().Parent = SelectedItem
- OpenButton.Name = "OpenButton"
- OpenButton.AnchorPoint = Vector2.new(0.5, 1)
- OpenButton.BackgroundColor3 = Color3.new(0.756863, 0.8, 0.85098)
- OpenButton.BorderSizePixel = 0
- OpenButton.Position = UDim2.new(0.5, 0, 1, -4)
- OpenButton.Size = UDim2.new(1, -12, 0, 12)
- OpenButton.Font = Enum.Font.ArialBold
- OpenButton.Text = "â–¼"
- OpenButton.TextColor3 = Color3.new(0.407843, 0.407843, 0.407843)
- OpenButton.TextSize = 12
- OpenButton.TextYAlignment = Enum.TextYAlignment.Bottom
- MenuFrame.Name = "MenuFrame"
- MenuFrame.BackgroundColor3 = Color3.new(1, 1, 1)
- MenuFrame.BackgroundTransparency = 1
- MenuFrame.BorderSizePixel = 0
- MenuFrame.ClipsDescendants = true
- MenuFrame.Position = UDim2.new(0, 0, 1, 0)
- MenuFrame.Size = UDim2.new(1, 0, 0, 32)
- Menu.Name = "Menu"
- Menu.BackgroundColor3 = Color3.new(0.0431373, 0.0431373, 0.0627451)
- Menu.BorderSizePixel = 0
- Menu.ClipsDescendants = true
- Menu.Position = UDim2.new(0, 0, -1, -8)
- Menu.Size = UDim2.new(1, 0, 1, 0)
- UIPadding.PaddingBottom = UDim.new(0, 2)
- UIPadding.PaddingLeft = UDim.new(0, 4)
- UIPadding.PaddingRight = UDim.new(0, 4)
- UIPadding.PaddingTop = UDim.new(0, 10)
- UIListLayout.HorizontalAlignment = Enum.HorizontalAlignment.Center
- UIListLayout.SortOrder = Enum.SortOrder.LayoutOrder
- UIListLayout.Padding = UDim.new(0, 4)
- Option.Name = "Option"
- Option.BackgroundColor3 = Color3.new(0.0745098, 0.0745098, 0.105882)
- Option.BorderSizePixel = 0
- Option.Size = UDim2.new(1, 0, 0, 18)
- Option.Font = Enum.Font.ArialBold
- Option.Text = "head"
- Option.TextColor3 = Color3.new(1, 1, 1)
- Option.TextSize = 14
- OptionName.AnchorPoint = Vector2.new(0.5, 0.5)
- OptionName.BackgroundColor3 = Color3.new(0.0431373, 0.0431373, 0.0627451)
- OptionName.Position = UDim2.new(0.5, 0, 0.5, 0)
- OptionName.Size = UDim2.new(1, -4, 1, -4)
- OptionName.Font = Enum.Font.ArialBold
- OptionName.Text = "option"
- OptionName.TextColor3 = Color3.new(1, 1, 1)
- OptionName.TextSize = 11
- OptionName.Name = "OptionName"
- NameText.Name = "NameText"
- NameText.BackgroundColor3 = Color3.new(1, 1, 1)
- NameText.BackgroundTransparency = 1
- NameText.BorderSizePixel = 0
- NameText.Position = UDim2.new(0, 8, 0, 0)
- NameText.Size = UDim2.new(1, -8, 0, 20)
- NameText.Font = Enum.Font.ArialBold
- NameText.Text = ""
- NameText.TextColor3 = Color3.new(1, 1, 1)
- NameText.TextSize = 14
- NameText.TextXAlignment = Enum.TextXAlignment.Left
- SelectedItem.Name = "SelectedItem"
- SelectedItem.AnchorPoint = Vector2.new(0.5, 0)
- SelectedItem.BackgroundColor3 = Color3.new(0.054902, 0.054902, 0.0784314)
- SelectedItem.BorderSizePixel = 0
- SelectedItem.Position = UDim2.new(0.5, 0, 0, 20)
- SelectedItem.Size = UDim2.new(1, -20, 0, 14)
- SelectedItem.Font = Enum.Font.ArialBold
- SelectedItem.Text = "n/a"
- SelectedItem.TextColor3 = Color3.new(0.756863, 0.8, 0.85098)
- SelectedItem.TextSize = 11
- OpenButton.MouseButton1Click:Connect(function()
- game:GetService("TweenService"):Create(dropdown.Instance.OpenButton.MenuFrame.Menu,TweenInfo.new(.12),{Position=UDim2.new(0,0,0,-8)}):Play()
- end)
- Menu.MouseLeave:Connect(function()
- game:GetService("TweenService"):Create(dropdown.Instance.OpenButton.MenuFrame.Menu,TweenInfo.new(.12),{Position=UDim2.new(0,0,-1,-8)}):Play()
- end)
- dropdown.Instance.SelectedItem.Text = dropdown.Selected:lower()
- return setmetatable(dropdown,{
- __index = function(self,index)
- return index == "Update" and function(self)
- self.Instance.SelectedItem.Text = self.Selected:lower()
- self.Instance.NameText.Text = self.Name
- end or index == "UpdateList" and function(self)
- lib:RemoveChildrenWithWhitelist(self.Instance.OpenButton.MenuFrame.Menu,{UIPadding=true,UICorner=true,UIListLayout=true})
- self.Instance.OpenButton.MenuFrame.Size = UDim2.new(1,0,0,10+(#self.Items*4+#self.Items*18))
- for index,option in pairs(self.Items) do
- local ui = Option:Clone()
- ui.Parent = self.Instance.OpenButton.MenuFrame.Menu
- ui.OptionName.Text = option.Name
- ui.MouseButton1Click:Connect(function()
- self.Selected = option.Name
- game:GetService("TweenService"):Create(self.Instance.OpenButton.MenuFrame.Menu,TweenInfo.new(.12),{Position=UDim2.new(0,0,-1,-8)}):Play()
- self:Update()
- end)
- end
- end
- end,
- })
- end or index == "CreateKeyChoose" and function(self,properties)
- local keychoose = {}
- keychoose.Instance = Instance.new("Frame",self.Instance)
- keychoose.Instance.Position = properties.Position
- keychoose.Key = nil
- keychoose.Name = ""
- local ChangeKey = Instance.new("TextButton",keychoose.Instance)
- local NameText = Instance.new("TextLabel",keychoose.Instance)
- local UICorner = Instance.new("UICorner",keychoose.Instance)
- UICorner.CornerRadius = UDim.new(0,4)
- UICorner:Clone().Parent = ChangeKey
- keychoose.Instance.Name = "KeyChange"
- keychoose.Instance.BackgroundColor3 = Color3.new(0.0745098, 0.0745098, 0.105882)
- keychoose.Instance.Size = UDim2.new(0, 120, 0, 54)
- keychoose.Instance.SizeConstraint = Enum.SizeConstraint.RelativeXX
- ChangeKey.Name = "ChangeKey"
- ChangeKey.BackgroundColor3 = Color3.new(0.756863, 0.8, 0.85098)
- ChangeKey.BorderSizePixel = 0
- ChangeKey.Position = UDim2.new(0, 5, 0, 20)
- ChangeKey.Size = UDim2.new(0, 30, 0, 30)
- ChangeKey.Font = Enum.Font.ArialBold
- ChangeKey.LineHeight = 1
- ChangeKey.Text = "..."
- ChangeKey.TextColor3 = Color3.new(0.407843, 0.407843, 0.407843)
- ChangeKey.TextSize = 14
- NameText.Name = "NameText"
- NameText.BackgroundColor3 = Color3.new(1, 1, 1)
- NameText.BackgroundTransparency = 1
- NameText.BorderSizePixel = 0
- NameText.Position = UDim2.new(0, 8, 0, 0)
- NameText.Size = UDim2.new(1, -8, 0, 20)
- NameText.Font = Enum.Font.ArialBold
- NameText.Text = ""
- NameText.TextColor3 = Color3.new(1, 1, 1)
- NameText.TextSize = 14
- NameText.TextXAlignment = Enum.TextXAlignment.Left
- keychoose.Instance.NameText.Text = keychoose.Name
- keychoose.Instance.ChangeKey.MouseButton1Click:Connect(function()
- local oldvalue,mouse = keychoose.Key,nil
- keychoose.Instance.ChangeKey.Text = "..."
- game:GetService("TweenService"):Create(keychoose.Instance.ChangeKey,TweenInfo.new(.12),{Size=UDim2.new(0,30,0,30)}):Play()
- local leftmouseconnection = lib.Mouse.Button1Down:Connect(function()mouse="l";end)
- local rightmouseconnection = lib.Mouse.Button2Down:Connect(function()mouse="r";end)
- local keyconnection;keyconnection = game:GetService("UserInputService").InputBegan:Connect(function(input)
- task.wait()
- keychoose.Key = (input.KeyCode == Enum.KeyCode.Unknown and mouse == nil) and oldvalue or input.KeyCode == Enum.KeyCode.Unknown and (mouse == "l" and "RightMouse" or "LeftMouse") or input.KeyCode
- keychoose:Update()
- keyconnection:Disconnect()
- leftmouseconnection:Disconnect()
- rightmouseconnection:Disconnect()
- end)
- end)
- return setmetatable(keychoose,{
- __index = function(self,index)
- return index == "Update" and function(self)
- if properties.OnUpdate then
- properties:OnUpdate()
- end
- self.Instance.NameText.Text = self.Name
- if typeof(self.Key) == "string" then
- self.Instance.ChangeKey.Text = self.Key
- else
- self.Instance.ChangeKey.Text = tostring(self.Key):sub(14,#tostring(self.Key))
- end
- game:GetService("TweenService"):Create(self.Instance.ChangeKey,TweenInfo.new(.12),{Size=UDim2.new(0,self.Instance.ChangeKey.TextBounds.X+18,0,30)}):Play()
- end
- end,
- })
- end or index == "CreatePushButton" and function(self,properties)
- local pushbutton = {}
- pushbutton.Instance = nil
- pushbutton.Name = ""
- pushbutton.OnUpdate = nil
- return setmetatable(pushbutton,{
- __index = function(self,index)
- return index == "Update" and function(self)
- end
- end,
- })
- end
- end,
- })
- end or index == "CloseViewFrames" and function(self)
- for frame,table in pairs(self.ViewFrames) do
- frame.Instance.Visible = false
- if table.LinkedButton then
- game:GetService("TweenService"):Create(table.LinkedButton.Instance,TweenInfo.new(.12),{BackgroundColor3=Color3.fromRGB(14,14,20)}):Play()
- end
- end
- end or index == "CreateCustomContainer" and function(self)
- end
- end,
- })
- end or index == "RemoveChildrenWithWhitelist" and function(self,Instance,whitelist)
- for _,child in pairs(Instance:GetChildren()) do
- if not whitelist[child.ClassName] then
- child:Destroy()
- end
- end
- end or index == "DP" and function(self,text,color)
- if color then
- rconsoleprint("@@"..color:upper().."@@")
- end
- rconsoleprint(text)
- rconsoleprint("@@LIGHT_GRAY@@")
- end or index == "Notify" and function(self,text)
- end or index == "MakeMoveable" and function(self,ui)
- if ui then
- if ui:IsA("Frame") then
- ui.Draggable = true
- elseif ui:IsA("TextButton") then
- local id,runservice = game:GetService("HttpService"):GenerateGUID(),game:GetService("RunService")
- ui.MouseButton1Down:Connect(function()
- local offset = ui.AbsolutePosition-Vector2.new(self.Mouse.X,self.Mouse.Y)
- self[id] = true
- repeat runservice.RenderStepped:Wait()
- ui.Position = UDim2.new(0,self.Mouse.X+offset.X,0,self.Mouse.Y+offset.Y)
- until not self[id]
- end)
- ui.MouseButton1Up:Connect(function()
- self[id] = false
- end)
- end
- end
- end
- end,
- })
- return lib
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement