Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for i,v in pairs(data) do
- pos = pos + 24
- Back.CanvasSize = UDim2.new(1,0,0,pos+48)
- if v.Type == 'Button' then
- -- Making the Button
- local Button = Make('TextButton',{
- Text = i,
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.9,0,0,20),
- Position = UDim2.new(.05,0,0,pos+12),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Back,
- })
- Roundify(Button)
- -- Hovering Events
- Button.MouseEnter:connect(function()
- spawn(function()
- Button:GetChildren()[1].ImageTransparency = .3
- end)
- end)
- Button.MouseLeave:connect(function()
- Button:GetChildren()[1].ImageTransparency = 0
- end)
- -- Clicked Event
- Button.MouseButton1Click:connect(function()
- spawn(v.Callback)
- end)
- elseif v.Type == 'Toggle' then
- local Button = Make('TextButton',{
- Text = i,
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.45,0,0,20),
- Position = UDim2.new(.05,0,0,pos+12),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Back,
- })
- Roundify(Button)
- local Toggle = Make('TextButton',{
- Text = '',
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.5,0,1,0),
- Position = UDim2.new(1.5,0,0,0),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Button,
- })
- Roundify(Toggle)
- Toggle.MouseButton1Click:connect(function()
- Settings[i] = not Settings[i]
- if (Settings[i]) then
- Toggle.Text = 'X'
- else
- Toggle.Text = ''
- end
- end)
- Toggle.MouseEnter:connect(function()
- spawn(function()
- Toggle:GetChildren()[1].ImageTransparency = .3
- end)
- end)
- Toggle.MouseLeave:connect(function()
- Toggle:GetChildren()[1].ImageTransparency = 0
- end)
- elseif v.Type == 'KeybindToggle' then
- local Button = Make('TextButton',{
- Text = i,
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.45,0,0,20),
- Position = UDim2.new(.05,0,0,pos+12),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Back,
- })
- Roundify(Button)
- local Toggle = Make('TextButton',{
- Text = 'X',
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.5,0,1,0),
- Position = UDim2.new(1.5,0,0,0),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Button,
- })
- Toggle.MouseButton1Click:connect(function()
- Settings[i] = not Settings[i]
- if (Settings[i]) then
- Toggle.Text = 'X'
- else
- Toggle.Text = ''
- end
- end)
- Roundify(Toggle)
- local KeyBind = Make('TextButton',{
- Text = '...',
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.40,0,1,0),
- Position = UDim2.new(1.05,0,0,0),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Button,
- })
- Roundify(KeyBind)
- Toggle.MouseEnter:connect(function()
- spawn(function()
- Toggle:GetChildren()[1].ImageTransparency = .3
- end)
- end)
- Toggle.MouseLeave:connect(function()
- Toggle:GetChildren()[1].ImageTransparency = 0
- end)
- KeyBind.MouseEnter:connect(function()
- spawn(function()
- KeyBind:GetChildren()[1].ImageTransparency = .3
- end)
- end)
- KeyBind.MouseLeave:connect(function()
- KeyBind:GetChildren()[1].ImageTransparency = 0
- end)
- elseif v.Type == 'Keybind' then
- local Button = Make('TextButton',{
- Text = i,
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.45,0,0,20),
- Position = UDim2.new(.05,0,0,pos+12),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Back,
- })
- Roundify(Button)
- local KeyBind = Make('TextButton',{
- Text = '...',
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.5,0,1,0),
- Position = UDim2.new(1.5,0,0,0),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Button,
- })
- Roundify(KeyBind)
- KeyBind.MouseEnter:connect(function()
- spawn(function()
- KeyBind:GetChildren()[1].ImageTransparency = .3
- end)
- end)
- KeyBind.MouseLeave:connect(function()
- KeyBind:GetChildren()[1].ImageTransparency = 0
- end)
- elseif v.Type == 'Input' then
- local Button = Make('TextButton',{
- Text = i,
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.45,0,0,20),
- Position = UDim2.new(.05,0,0,pos+12),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Back,
- })
- Roundify(Button)
- local KeyBind = Make('TextBox',{
- Text = '',
- PlaceholderText = 'idk',
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.95,0,1,0),
- Position = UDim2.new(1.05,0,0,0),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Button,
- })
- Roundify(KeyBind)
- KeyBind.FocusLost:connect(function()
- Settings[i]=KeyBind.Text
- end)
- KeyBind.MouseEnter:connect(function()
- spawn(function()
- KeyBind:GetChildren()[1].ImageTransparency = .3
- end)
- end)
- KeyBind.MouseLeave:connect(function()
- KeyBind:GetChildren()[1].ImageTransparency = 0
- end)
- elseif v.Type == 'InputButton' then
- local Button = Make('TextButton',{
- Text = i,
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.45,0,0,20),
- Position = UDim2.new(.05,0,0,pos+12),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Back,
- })
- Roundify(Button)
- local Toggle = Make('TextButton',{
- Text = 'X',
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.5,0,1,0),
- Position = UDim2.new(1.5,0,0,0),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Button,
- })
- Roundify(Toggle)
- local KeyBind = Make('TextBox',{
- Text = '...',
- TextColor3 = Color3.new(1,1,1),
- Size = UDim2.new(.40,0,1,0),
- Position = UDim2.new(1.05,0,0,0),
- BackgroundColor3 = Color3.new(.3,.3,.3),
- Parent = Button,
- })
- Roundify(KeyBind)
- KeyBind.FocusLost:connect(function()
- Settings[i]=KeyBind.Text
- end)
- Toggle.MouseEnter:connect(function()
- spawn(function()
- Toggle:GetChildren()[1].ImageTransparency = .3
- end)
- end)
- Toggle.MouseLeave:connect(function()
- Toggle:GetChildren()[1].ImageTransparency = 0
- end)
- KeyBind.MouseEnter:connect(function()
- spawn(function()
- KeyBind:GetChildren()[1].ImageTransparency = .3
- end)
- end)
- KeyBind.MouseLeave:connect(function()
- KeyBind:GetChildren()[1].ImageTransparency = 0
- end)
- Toggle.MouseButton1Click:connect(function()
- spawn(v.Callback)
- end)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement